/* ============================================================
   Take the Ideas — Core Stylesheet
   ============================================================ */

:root {
  --navy-950: #070c1a;
  --navy-900: #0b1330;
  --navy-800: #101c44;
  --gold-300: #e2bd63;
  --gold-400: #d4a93f;
  --gold-500: #c39530;
}

html {
  scroll-behavior: smooth;
}

body {
  overflow-x: hidden;
}

::selection {
  background: rgba(212, 169, 63, 0.35);
  color: #fff;
}

/* Scrollbar */
::-webkit-scrollbar { width: 10px; }
::-webkit-scrollbar-track { background: #070c1a; }
::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #d4a93f, #a67a24);
  border-radius: 10px;
}

/* ---------- Utility: Gold text gradient ---------- */
.text-gold-gradient {
  background: linear-gradient(110deg, #f5e8c2 0%, #d4a93f 35%, #a67a24 60%, #f5e8c2 100%);
  background-size: 220% auto;
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
  animation: shine 6s linear infinite;
}

@keyframes shine {
  to { background-position: 220% center; }
}

/* ---------- Background texture ---------- */
.bg-grid {
  background-image:
    linear-gradient(to right, rgba(212,169,63,0.05) 1px, transparent 1px),
    linear-gradient(to bottom, rgba(212,169,63,0.05) 1px, transparent 1px);
  background-size: 48px 48px;
}

.bg-radial-glow {
  background: radial-gradient(circle at 50% 0%, rgba(212,169,63,0.18), transparent 55%);
}

.hero-noise::before {
  content: "";
  position: absolute;
  inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='120' height='120'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='2' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.035'/%3E%3C/svg%3E");
  pointer-events: none;
}

/* ---------- Header ---------- */
#site-header {
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  transition: background-color 0.35s ease, box-shadow 0.35s ease, padding 0.35s ease;
}

#site-header.scrolled {
  background-color: rgba(7, 12, 26, 0.86);
  box-shadow: 0 10px 30px -15px rgba(0,0,0,0.6), 0 0 0 1px rgba(212,169,63,0.08);
}

.nav-link {
  position: relative;
  color: #cbd5e1;
  transition: color 0.25s ease;
}
.nav-link::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 0%;
  height: 1px;
  background: linear-gradient(90deg, #d4a93f, #f5e8c2);
  transition: width 0.3s ease;
}
.nav-link:hover { color: #f5e8c2; }
.nav-link:hover::after { width: 100%; }

/* ---------- Buttons ---------- */
.btn-gold {
  position: relative;
  overflow: hidden;
  background: linear-gradient(120deg, #f5e8c2, #d4a93f 45%, #a67a24 100%);
  color: #0b1330;
  font-weight: 600;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
  box-shadow: 0 10px 25px -10px rgba(212,169,63,0.55);
}
.btn-gold:hover {
  transform: translateY(-2px);
  box-shadow: 0 16px 32px -12px rgba(212,169,63,0.75);
}
.btn-gold:active { transform: translateY(0); }

.btn-gold::before {
  content: "";
  position: absolute;
  top: 0;
  left: -75%;
  width: 50%;
  height: 100%;
  background: linear-gradient(120deg, transparent, rgba(255,255,255,0.55), transparent);
  transform: skewX(-20deg);
  transition: left 0.65s ease;
}
.btn-gold:hover::before { left: 130%; }

.btn-outline {
  border: 1px solid rgba(212,169,63,0.45);
  color: #ecd493;
  transition: all 0.3s ease;
}
.btn-outline:hover {
  border-color: rgba(212,169,63,0.9);
  background: rgba(212,169,63,0.08);
  transform: translateY(-2px);
}

/* ---------- Cards ---------- */
.card {
  background: linear-gradient(180deg, rgba(16,28,68,0.6), rgba(10,17,45,0.55));
  border: 1px solid rgba(212,169,63,0.12);
  transition: transform 0.35s ease, box-shadow 0.35s ease, border-color 0.35s ease;
}
.card:hover {
  transform: translateY(-6px);
  border-color: rgba(212,169,63,0.4);
  box-shadow: 0 24px 45px -20px rgba(0,0,0,0.65), 0 0 0 1px rgba(212,169,63,0.15);
}

.icon-badge {
  background: radial-gradient(circle at 30% 20%, rgba(212,169,63,0.35), rgba(212,169,63,0.05));
  border: 1px solid rgba(212,169,63,0.35);
}

/* ---------- Fade-in on scroll ---------- */
.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Section divider ---------- */
.divider-gold {
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(212,169,63,0.5), transparent);
}

/* ---------- Chess pattern strip ---------- */
.chess-strip {
  background-image:
    linear-gradient(45deg, rgba(212,169,63,0.06) 25%, transparent 25%),
    linear-gradient(-45deg, rgba(212,169,63,0.06) 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, rgba(212,169,63,0.06) 75%),
    linear-gradient(-45deg, transparent 75%, rgba(212,169,63,0.06) 75%);
  background-size: 24px 24px;
  background-position: 0 0, 0 12px, 12px -12px, -12px 0px;
}

/* ---------- Marquee tools strip ---------- */
.marquee-track {
  display: flex;
  width: max-content;
  animation: marquee 28s linear infinite;
}
@keyframes marquee {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

/* ---------- Form ---------- */
.form-input {
  background: rgba(255,255,255,0.03);
  border: 1px solid rgba(212,169,63,0.22);
  transition: border-color 0.25s ease, box-shadow 0.25s ease, background 0.25s ease;
}
.form-input:focus {
  outline: none;
  border-color: rgba(212,169,63,0.75);
  box-shadow: 0 0 0 3px rgba(212,169,63,0.15);
  background: rgba(255,255,255,0.05);
}

/* ---------- Logo glow ---------- */
.logo-glow {
  filter: drop-shadow(0 0 10px rgba(212,169,63,0.35));
}

/* ---------- Prompting technique chip ---------- */
.chip {
  border: 1px solid rgba(212,169,63,0.25);
  background: rgba(212,169,63,0.06);
  transition: all 0.25s ease;
}
.chip:hover {
  background: rgba(212,169,63,0.15);
  border-color: rgba(212,169,63,0.55);
}

/* ---------- Mobile nav ---------- */
#mobile-menu {
  transition: max-height 0.4s ease, opacity 0.3s ease;
  max-height: 0;
  opacity: 0;
  overflow: hidden;
}
#mobile-menu.open {
  max-height: 500px;
  opacity: 1;
}

/* ---------- Stat counter ---------- */
.stat-number {
  font-variant-numeric: tabular-nums;
}

/* Utility for hidden scrollbar on marquee wrapper */
.no-scrollbar::-webkit-scrollbar { display: none; }
.no-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }

/* ---------- AI Concierge Chatbot ---------- */
.chat-fab {
  background: linear-gradient(135deg, #ecd493, #c39530);
  box-shadow: 0 10px 30px -8px rgba(212, 169, 63, 0.55), 0 0 0 1px rgba(212, 169, 63, 0.35);
  border: none;
  cursor: pointer;
  transition: transform 0.25s ease, box-shadow 0.25s ease;
}
.chat-fab:hover {
  transform: translateY(-2px) scale(1.04);
  box-shadow: 0 14px 34px -6px rgba(212, 169, 63, 0.65), 0 0 0 1px rgba(212, 169, 63, 0.45);
}
.chat-fab::after {
  content: '';
  position: absolute;
  inset: -6px;
  border-radius: 9999px;
  border: 1px solid rgba(212, 169, 63, 0.35);
  animation: chat-pulse 2.6s ease-out infinite;
  pointer-events: none;
}
@keyframes chat-pulse {
  0% { transform: scale(0.9); opacity: 0.6; }
  70% { transform: scale(1.35); opacity: 0; }
  100% { opacity: 0; }
}

.chat-window {
  background: linear-gradient(180deg, #0d1638 0%, #0a1230 100%);
  border: 1px solid rgba(212, 169, 63, 0.22);
  box-shadow: 0 25px 60px -15px rgba(0, 0, 0, 0.65), 0 0 0 1px rgba(212, 169, 63, 0.08);
  display: none;
  height: min(560px, calc(100vh - 9rem));
}
.chat-window.open {
  display: flex;
  animation: chat-window-in 0.28s ease;
}
@keyframes chat-window-in {
  from { opacity: 0; transform: translateY(14px) scale(0.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

.chat-header {
  border-bottom: 1px solid rgba(212, 169, 63, 0.14);
  background: rgba(255, 255, 255, 0.02);
  flex-shrink: 0;
}

.chat-messages {
  flex: 1 1 auto;
  min-height: 0;
}
.chat-messages::-webkit-scrollbar { width: 5px; }
.chat-messages::-webkit-scrollbar-thumb { background: rgba(212, 169, 63, 0.3); border-radius: 9999px; }

.chat-bubble {
  max-width: 88%;
  padding: 0.65rem 0.9rem;
  border-radius: 1rem;
  font-size: 0.85rem;
  line-height: 1.5;
  word-wrap: break-word;
  white-space: pre-wrap;
}
.chat-bubble.user {
  margin-left: auto;
  background: linear-gradient(135deg, #ecd493, #c39530);
  color: #0b1330;
  border-bottom-right-radius: 0.3rem;
  font-weight: 500;
}
.chat-bubble.assistant {
  margin-right: auto;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(212, 169, 63, 0.14);
  color: #cbd5e1;
  border-bottom-left-radius: 0.3rem;
}
.chat-bubble.error {
  border-color: rgba(239, 68, 68, 0.35);
  color: #fca5a5;
}

.chat-typing {
  display: inline-flex;
  gap: 4px;
  align-items: center;
  padding: 0.2rem 0;
}
.chat-typing span {
  width: 6px;
  height: 6px;
  border-radius: 9999px;
  background: rgba(212, 169, 63, 0.7);
  animation: chat-typing-bounce 1.1s infinite ease-in-out;
}
.chat-typing span:nth-child(2) { animation-delay: 0.15s; }
.chat-typing span:nth-child(3) { animation-delay: 0.3s; }
@keyframes chat-typing-bounce {
  0%, 60%, 100% { transform: translateY(0); opacity: 0.5; }
  30% { transform: translateY(-4px); opacity: 1; }
}

.chip-suggestion {
  font-size: 0.7rem;
  color: #ecd493;
  background: rgba(212, 169, 63, 0.08);
  border: 1px solid rgba(212, 169, 63, 0.2);
  border-radius: 9999px;
  padding: 0.35rem 0.7rem;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease;
}
.chip-suggestion:hover {
  background: rgba(212, 169, 63, 0.18);
  color: #fbf5e6;
}

.chat-input-row {
  border-top: 1px solid rgba(212, 169, 63, 0.14);
  background: rgba(255, 255, 255, 0.02);
  flex-shrink: 0;
}
.chat-input {
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(212, 169, 63, 0.18);
}
.chat-input:focus {
  outline: none;
  border-color: rgba(212, 169, 63, 0.5);
  background: rgba(255, 255, 255, 0.06);
}
.chat-send-btn {
  background: linear-gradient(135deg, #ecd493, #c39530);
  color: #0b1330;
  border: none;
  cursor: pointer;
  transition: transform 0.2s ease;
}
.chat-send-btn:hover { transform: scale(1.06); }
.chat-send-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

@media (max-width: 480px) {
  .chat-window { height: min(70vh, 520px); }
}

/* ===================== ROI / SAVINGS CALCULATOR ===================== */
.roi-slider {
  -webkit-appearance: none;
  appearance: none;
  height: 6px;
  border-radius: 9999px;
  background: rgba(212, 169, 63, 0.15);
  cursor: pointer;
  outline: none;
}
.roi-slider::-webkit-slider-thumb {
  -webkit-appearance: none;
  appearance: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ecd493, #c39530);
  border: 2px solid #070c1a;
  box-shadow: 0 0 0 1px rgba(212, 169, 63, 0.4), 0 2px 8px rgba(0, 0, 0, 0.4);
  cursor: pointer;
  transition: transform 0.15s ease;
}
.roi-slider::-webkit-slider-thumb:hover { transform: scale(1.15); }
.roi-slider::-moz-range-thumb {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  background: linear-gradient(135deg, #ecd493, #c39530);
  border: 2px solid #070c1a;
  box-shadow: 0 0 0 1px rgba(212, 169, 63, 0.4), 0 2px 8px rgba(0, 0, 0, 0.4);
  cursor: pointer;
}
.roi-slider::-moz-range-track {
  height: 6px;
  border-radius: 9999px;
  background: rgba(212, 169, 63, 0.15);
}

.roi-meter-track {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(212, 169, 63, 0.12);
}
.roi-meter-bar {
  background: linear-gradient(90deg, #4ade80, #d4a93f);
  transition: width 0.35s ease;
}
