* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
}

body {
  background: linear-gradient(135deg, #0f172a 0%, #1e3a8a 100%);
  color: #e2e8f0;
  line-height: 1.6;
  min-height: 100vh;
}

#app {
  min-height: 100vh;
  padding: 20px;
}

.container {
  display: flex;
  max-width: 1400px;
  margin: 0 auto;
  background-color: rgba(255, 255, 255, 0.08);
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
  overflow: hidden;
  min-height: 90vh;
  backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Left Panel Styles */
.left-panel {
  width: 40%;
  padding: 2.5rem;
  background-color: rgba(248, 250, 252, 0.05);
  overflow-y: auto;
  max-height: 90vh;
  backdrop-filter: blur(8px);
  border-right: 1px solid rgba(255, 255, 255, 0.05);
}

.left-panel h1 {
  font-size: 1.8rem;
  color: #f8fafc;
  margin-bottom: 1.5rem;
  font-weight: 700;
  letter-spacing: -0.025em;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.upload-section {
  margin-bottom: 2.5rem;
  text-align: center;
}

.upload-btn {
  display: inline-block;
  background-color: rgba(59, 130, 246, 0.8);
  color: white;
  padding: 12px 24px;
  border-radius: 8px;
  cursor: pointer;
  transition: all 0.2s ease;
  font-weight: 500;
  box-shadow: 0 2px 10px rgba(59, 130, 246, 0.3);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.upload-btn:hover {
  background-color: rgba(37, 99, 235, 0.9);
  transform: translateY(-1px);
  box-shadow: 0 4px 15px rgba(59, 130, 246, 0.4);
}

input[type="file"] {
  display: none;
}

.upload-hint {
  margin-top: 1rem;
  color: #cbd5e1;
  font-size: 0.9rem;
}

.loading-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, rgba(15, 23, 42, 0.95) 0%, rgba(30, 58, 138, 0.95) 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 10000;
  backdrop-filter: blur(12px);
  transition: all 0.3s ease;
  opacity: 1;
  pointer-events: all;
}

.app-content {
  transition: filter 0.3s ease, opacity 0.3s ease;
}

.is-analyzing .app-content {
  filter: blur(5px);
  opacity: 0.6;
  pointer-events: none;
}

.loading-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: white;
  text-align: center;
  background: rgba(0, 0, 0, 0.25);
  padding: 40px;
  border-radius: 20px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
  border: 1px solid rgba(255, 255, 255, 0.1);
  animation: pulse 2s infinite ease-in-out;
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0.5); }
  70% { box-shadow: 0 0 0 20px rgba(59, 130, 246, 0); }
  100% { box-shadow: 0 0 0 0 rgba(59, 130, 246, 0); }
}

.loading-content p {
  margin-top: 1.5rem;
  font-size: 1.2rem;
  font-weight: 500;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
  animation: fadeInOut 1.5s infinite;
}

@keyframes fadeInOut {
  0% { opacity: 0.7; }
  50% { opacity: 1; }
  100% { opacity: 0.7; }
}

.lava-lamp {
  position: relative;
  width: 80px;
  height: 140px;
  background: rgba(0, 0, 0, 0.7);
  border-radius: 40px;
  overflow: hidden;
  margin: 0 auto;
  box-shadow: 0 0 25px rgba(59, 130, 246, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.bubble {
  position: absolute;
  top: 0;
  width: 24px;
  height: 24px;
  background: linear-gradient(to bottom, #e64980, #ff8787);
  border-radius: 50%;
  left: 15px;
  animation: drop 5s ease-in-out infinite;
  box-shadow: 0 0 10px rgba(230, 73, 128, 0.6);
}

.bubble1 {
  position: absolute;
  top: 0;
  width: 24px;
  height: 24px;
  background: linear-gradient(to bottom, #82c91e, #3bc9db);
  border-radius: 50%;
  left: 1px;
  animation: drop 3s ease-in-out infinite;
  box-shadow: 0 0 10px rgba(130, 201, 30, 0.6);
}

.bubble2 {
  position: absolute;
  top: 0;
  width: 24px;
  height: 24px;
  background: linear-gradient(to bottom, #7950f2, #f783ac);
  border-radius: 50%;
  left: 30px;
  animation: drop 4s ease-in-out infinite;
  box-shadow: 0 0 10px rgba(121, 80, 242, 0.6);
}

.bubble3 {
  position: absolute;
  top: 0;
  width: 24px;
  height: 24px;
  background: linear-gradient(to bottom, #4481eb, #04befe);
  border-radius: 50%;
  left: 20px;
  animation: drop 6s ease-in-out infinite;
  box-shadow: 0 0 10px rgba(68, 129, 235, 0.6);
}

@keyframes drop {
  0% {
    transform: translateY(0px);
  }
  50% {
    transform: translateY(80px);
  }
  100% {
    transform: translateY(0px);
  }
}

.analysis-section {
  margin-top: 2rem;
}

.analysis-section h2 {
  font-size: 1.4rem;
  margin-bottom: 1.5rem;
  color: #f1f5f9;
  font-weight: 600;
  letter-spacing: -0.025em;
  text-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
}

.metric {
  margin-bottom: 1.4rem;
}

.metric-header {
  display: flex;
  justify-content: space-between;
  margin-bottom: 0.5rem;
}

.metric-name {
  font-weight: 500;
  color: #cbd5e1;
  font-size: 0.95rem;
}

.metric-score {
  font-weight: 600;
  color: #f1f5f9;
}

.metric-bar-container {
  width: 100%;
  height: 8px;
  background-color: rgba(226, 232, 240, 0.1);
  border-radius: 4px;
  overflow: hidden;
  backdrop-filter: blur(2px);
}

.metric-bar {
  height: 100%;
  transition: width 0.6s cubic-bezier(0.16, 1, 0.3, 1);
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.5);
}

.feedback-section, .strengths-section, .improvements-section {
  margin-top: 2.2rem;
  padding: 1.5rem;
  background-color: rgba(255, 255, 255, 0.05);
  border-radius: 12px;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1);
  transition: transform 0.2s ease;
  backdrop-filter: blur(6px);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.feedback-section:hover, .strengths-section:hover, .improvements-section:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
}

.feedback-section h3, .strengths-section h3, .improvements-section h3 {
  color: #f1f5f9;
  margin-bottom: 1rem;
  font-size: 1.1rem;
  font-weight: 600;
  text-shadow: 0 2px 3px rgba(0, 0, 0, 0.2);
}

.feedback-text {
  color: #cbd5e1;
  line-height: 1.6;
}

ul {
  padding-left: 1.5rem;
}

li {
  margin-bottom: 0.8rem;
  color: #cbd5e1;
  position: relative;
}

.annotation-reference {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  background-color: rgba(59, 130, 246, 0.8);
  color: white;
  border-radius: 50%;
  font-size: 0.7rem;
  font-weight: 600;
  margin-right: 6px;
  box-shadow: 0 0 10px rgba(59, 130, 246, 0.3);
}

/* Right Panel Styles */
.right-panel {
  width: 60%;
  background-color: rgba(255, 255, 255, 0.02);
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 15px;
  overflow: hidden;
  position: relative;
  backdrop-filter: blur(5px);
}

.image-container {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}

.image-container img {
  max-width: 95%;
  max-height: 95%;
  object-fit: contain;
  border-radius: 12px;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.2);
  transition: transform 0.3s ease;
}

.annotation {
  position: absolute;
  transform: translate(-50%, -50%);
  z-index: 10;
}

.annotation-bubble {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 28px;
  height: 28px;
  background-color: rgba(59, 130, 246, 0.85);
  color: white;
  border-radius: 50%;
  font-size: 0.9rem;
  font-weight: 600;
  box-shadow: 0 0 12px rgba(59, 130, 246, 0.4);
  cursor: pointer;
  transition: all 0.2s ease;
  backdrop-filter: blur(3px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

.annotation-bubble:hover {
  transform: scale(1.1);
  background-color: rgba(59, 130, 246, 1);
  box-shadow: 0 0 15px rgba(59, 130, 246, 0.6);
}

.annotation-arrow {
  position: absolute;
  width: 30px;
  height: 30px;
  border-left: 2px solid rgba(59, 130, 246, 0.8);
  border-bottom: 2px solid rgba(59, 130, 246, 0.8);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.annotation:hover .annotation-arrow {
  opacity: 1;
}

.placeholder {
  text-align: center;
  color: #94a3b8;
  padding: 2rem;
}

.placeholder img {
  width: 100px;
  opacity: 0.6;
  margin-bottom: 1.5rem;
  transition: all 0.3s ease;
  filter: drop-shadow(0 0 10px rgba(59, 130, 246, 0.2));
}

.placeholder:hover img {
  opacity: 0.8;
  transform: scale(1.05);
}

@media (max-width: 1024px) {
  .container {
    flex-direction: column;
  }
  
  .left-panel, .right-panel {
    width: 100%;
  }
  
  .right-panel {
    min-height: 400px;
  }
}