@import url('https://fonts.googleapis.com/css2?family=Poppins:wght@400;600;700&display=swap');

:root {
  --primary: #212121;
  --primary-dark: #252525;
  --secondary: #292929;
  --dark: #1e1e1e;
  --light: #f8f8f8;
  --gray: #e0e0e0;
  --error: #ff6b6b;
  --success: #48dbb4;
  --warning: #ffc154;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Poppins', sans-serif;
}

body {
  background-color: var(--light);
  color: var(--dark);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  align-items: stretch;
  justify-content: flex-start;
}

.ai-header {
  width: 100%;
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  position: relative;
  z-index: 10;
}

.ai-logo {
  width: 40px;
  height: 40px;
  object-fit: contain;
  filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.2));
}

.ai-title {
  font-size: 1.2rem;
  font-weight: 400;
  letter-spacing: 0.5px;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  gap: 10px;
}

.ai-badge {
  background: linear-gradient(90deg, #8b7b1e 0%, #b8a84c 100%);
  color: #ffffff;
  padding: 0.25rem 0.75rem;
  border-radius: 100px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-left: 0.5rem;
  vertical-align: middle;
  border: none;
  box-shadow: 0 1px 4px rgba(255, 215, 0, 0.12);
}

.ai-main {
  flex: 1;
  padding: 2rem;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2rem;
  position: relative;
}

.ai-scan-container {
  width: 100%;
  max-width: 600px;
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  animation: fadeIn 0.5s ease-out;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(20px); }
  to { opacity: 1; transform: translateY(0); }
}

.ai-video-wrapper {
  position: relative;
  width: 100%;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 8px 32px rgba(0, 0, 0, 0.1);
  aspect-ratio: 4/3;
  background-color: var(--dark);
}

#video {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.ai-scan-btn {
  position: absolute;
  bottom: 1.5rem;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, var(--primary), var(--secondary));
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.2);
  transition: all 0.3s ease;
  z-index: 2;
}

.ai-scan-btn:hover {
  transform: translateX(-50%) scale(1.05);
  box-shadow: 0 6px 20px rgba(0, 0, 0, 0.25);
}

.ai-scan-btn:active {
  transform: translateX(-50%) scale(0.98);
}

.ai-scan-btn svg {
  width: 20px;
  height: 20px;
}

.ai-result-card, #result {
  background: none !important;
  border: none !important;
  box-shadow: none !important;
  color: #222 !important;
  font-size: 1.08rem;
  padding: 0 !important;
  margin: 0 !important;
  border-radius: 0 !important;
  min-height: 0 !important;
  width: 100%;
  text-align: left;
  animation: none !important;
  backdrop-filter: none !important;
  overflow: visible;
}

.banten-card {
  background: none;
  border-radius: 0;
  box-shadow: none;
  padding: 0;
  gap: 10px;
}

.banten-title {
  color: #1e1e1e;
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 2px;
  display: flex;
  align-items: center;
  gap: 8px;
  text-shadow: none;
}

.banten-kategori {
  color: #fff;
  background: #222;
  display: inline-block;
  border-radius: 6px;
  padding: 2px 10px;
  font-size: 0.98rem;
  font-weight: 600;
  margin-bottom: 6px;
  border: none;
  box-shadow: none;
}

.banten-section {
  margin-bottom: 8px;
}

.banten-label {
  color: #1e1e1e;
  font-weight: 600;
  margin-right: 4px;
  text-shadow: none;
}

.desc {
  color: #222;
  font-size: 1.01rem;
  margin-top: 2px;
  line-height: 1.6;
  text-shadow: none;
}

.youtube-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #1976d2;
  text-decoration: none;
  font-weight: 600;
  margin-top: 2px;
  font-size: 1rem;
  transition: color 0.2s;
  text-shadow: none;
}

.youtube-link:hover {
  color: #0d47a1;
  text-shadow: none;
}

.youtube-icon {
  width: 20px;
  height: 20px;
  vertical-align: middle;
  filter: none;
}

.ai-loading {
  color: #222;
  font-size: 1.05rem;
  font-weight: 500;
  letter-spacing: 1px;
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 40px;
  height: 40px;
  margin-bottom: 8px;
  font-family: 'Poppins', Arial, sans-serif;
}

.ai-dots {
  display: inline-block;
  width: 24px;
  text-align: left;
}

.ai-dot {
  opacity: 0.2;
  animation: aiDotBlink 1.2s infinite;
  font-weight: bold;
  font-size: 1.1em;
  color: #222;
}

.ai-dot:nth-child(2) { animation-delay: 0.2s; }
.ai-dot:nth-child(3) { animation-delay: 0.4s; }

@keyframes aiDotBlink {
  0%, 80%, 100% { opacity: 0.2; }
  40% { opacity: 1; }
}

.ai-footer {
  width: 100%;
  background: #1e1e1e;
  color: #bdbdbd;
  text-align: center;
  font-size: 0.98rem;
  font-weight: 500;
  padding: 14px 0 10px 0;
  border-top: 1.5px solid #e0e0e0;
  box-shadow: none;
  letter-spacing: 1px;
}

::-webkit-scrollbar {
  width: 8px;
  background: #f5f5f5;
}

::-webkit-scrollbar-thumb {
  background: #e0e0e0;
  border-radius: 8px;
}

@media (max-width: 600px) {
  body {
    font-size: 0.97rem;
  }
  .ai-header {
    padding: 0.7rem 0.5rem;
    font-size: 0.98rem;
    gap: 0.5rem;
  }
  .ai-logo {
    width: 32px;
    height: 32px;
  }
  .ai-title {
    font-size: 1rem;
    gap: 4px;
  }
  .ai-badge {
    font-size: 0.7rem;
    padding: 0.18rem 0.5rem;
    margin-left: 0.3rem;
  }
  .ai-main {
    padding: 0.5rem 0.5rem 1.2rem 0.5rem;
    gap: 1rem;
  }
  .ai-scan-container {
    max-width: 100vw;
    gap: 1rem;
  }
  .ai-video-wrapper {
    aspect-ratio: 1/1;
    border-radius: 10px;
    padding: 0;
  }
  #video {
    max-width: 98vw;
    border-radius: 8px;
  }
  .ai-scan-btn {
    font-size: 0.92rem;
    padding: 0.5rem 1rem;
    border-radius: 30px;
    bottom: 1rem;
  }
  .ai-result-card, #result {
    font-size: 0.98rem;
    padding: 0 2vw !important;
  }
  .banten-title {
    font-size: 1.05rem;
    gap: 4px;
  }
  .banten-kategori {
    font-size: 0.9rem;
    padding: 2px 7px;
    margin-bottom: 4px;
  }
  .banten-section {
    margin-bottom: 6px;
  }
  .youtube-link {
    font-size: 0.95rem;
    padding: 0.3rem 0.7rem;
  }
  .ai-footer {
    font-size: 0.92rem;
    padding: 10px 0 7px 0;
  }
  .hiasan { display: none !important; }
}

@media (max-width: 768px) {
  .ai-header {
    padding: 1rem;
  }
  .ai-title {
    font-size: 1.2rem;
  }
  .ai-main {
    padding: 1.5rem;
  }
  .ai-scan-btn {
    padding: 0.6rem 1.2rem;
    font-size: 0.9rem;
  }
}

@keyframes pulse {
  0% { box-shadow: 0 0 0 0 rgba(0, 201, 167, 0.4); }
  70% { box-shadow: 0 0 0 15px rgba(0, 201, 167, 0); }
  100% { box-shadow: 0 0 0 0 rgba(0, 201, 167, 0); }
}

.detected {
  animation: pulse 1.5s ease-out;
}

.permission-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background-color: rgba(0, 0, 0, 0.9);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  z-index: 100;
  color: white;
  text-align: center;
}

.permission-overlay h2 {
  font-size: 1.5rem;
  margin-bottom: 1rem;
  color: var(--primary);
}

.permission-overlay p {
  margin-bottom: 2rem;
  max-width: 500px;
}

.permission-btn {
  background-color: var(--primary);
  color: white;
  border: none;
  padding: 0.75rem 1.5rem;
  border-radius: 50px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.permission-btn:hover {
  background-color: var(--primary-dark);
  transform: translateY(-2px);
}

.ai-loading-text {
  display: inline-block;
  margin-right: 0.5em;
  animation: bounce 1.5s infinite ease-in-out;
}

.ai-cursor {
  display: inline-block;
  width: 1px;
  background: var(--dark);
  animation: blink-cursor 0.8s steps(1) infinite;
  margin-left: 1px;
  height: 1em;
  vertical-align: middle;
}

@keyframes blink-cursor {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.hiasan {
  position: fixed;
  top: 50%;
  transform: translateY(-50%);
  width: 100px;
  max-width: 40vw;
  opacity: 1;
  z-index: 1;
  pointer-events: none;
}
.hiasan-kiri {
  left: 0;
  top: 50%;
}
.hiasan-kanan {
  right: 0;
}
@media (max-width: 700px) {
  .hiasan { display: none; }
} 