/* ========================================
   Tarvon.ai — Global Stylesheet
   Brand: #0A0A0F bg, #C9A84C gold, Inter
   ======================================== */

@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* --- Reset & Base --- */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg-primary: #0A0A0F;
  --bg-secondary: #050508;
  --bg-card: #0d0d1a;
  --gold: #C9A84C;
  --gold-dim: #A8893D;
  --text-primary: #FFFFFF;
  --text-secondary: #E8E8EC;
  --text-muted: #8888A0;
  --border: #2a2a3a;
  --green: #4ADE80;
  --yellow: #FACC15;
  --red: #EF4444;
  --max-width: 1100px;
  --nav-height: 64px;
}

html { scroll-behavior: smooth; font-size: 16px; }

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg-primary);
  color: var(--text-secondary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--gold); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--text-primary); }

img { max-width: 100%; height: auto; display: block; }

/* --- Typography --- */
h1, h2, h3, h4 { color: var(--text-primary); font-weight: 700; line-height: 1.2; }
h1 { font-size: clamp(1.8rem, 4vw, 2.8rem); }
h2 { font-size: clamp(1.4rem, 3vw, 2rem); }
h3 { font-size: clamp(1.1rem, 2vw, 1.4rem); }
p { margin-bottom: 1rem; }

/* --- Layout --- */
.container { max-width: var(--max-width); margin: 0 auto; padding: 0 24px; }
.section { padding: 80px 0; }
.section-alt { background: var(--bg-secondary); }

/* --- Navigation --- */
.nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(10, 10, 15, 0.95); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  height: var(--nav-height);
}
.nav .container {
  display: flex; align-items: center; justify-content: space-between;
  height: 100%;
}
.nav-logo {
  font-weight: 700; font-size: 1.3rem; letter-spacing: 0.25em;
  color: var(--text-primary); text-decoration: none;
}
.nav-logo .v { color: var(--gold); }
.nav-links { display: flex; gap: 28px; align-items: center; list-style: none; }
.nav-links a {
  color: var(--text-muted); font-size: 0.9rem; font-weight: 500;
  transition: color 0.2s;
}
.nav-links a:hover, .nav-links a.active { color: var(--text-primary); }
.nav-cta {
  background: var(--gold); color: var(--bg-primary) !important;
  padding: 8px 20px; border-radius: 6px; font-weight: 600; font-size: 0.85rem;
}
.nav-cta:hover { background: var(--gold-dim); color: var(--bg-primary) !important; }

/* Mobile nav toggle */
.nav-toggle { display: none; background: none; border: none; color: var(--text-primary); font-size: 1.5rem; cursor: pointer; }

@media (max-width: 768px) {
  .nav-toggle { display: block; }
  .nav-links {
    display: none; flex-direction: column; position: absolute;
    top: var(--nav-height); left: 0; right: 0;
    background: var(--bg-primary); border-bottom: 1px solid var(--border);
    padding: 20px 24px; gap: 16px;
  }
  .nav-links.open { display: flex; }
}

/* --- Hero --- */
.hero {
  min-height: 80vh; display: flex; align-items: center;
  padding-top: calc(var(--nav-height) + 40px);
}
.hero-content { max-width: 700px; }
.hero h1 { margin-bottom: 20px; }
.hero h1 .gold { color: var(--gold); }
.hero p { font-size: 1.15rem; color: var(--text-muted); margin-bottom: 32px; max-width: 560px; }
.hero-actions { display: flex; gap: 16px; flex-wrap: wrap; }

/* --- Buttons --- */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 12px 28px; border-radius: 8px;
  font-weight: 600; font-size: 0.95rem; cursor: pointer;
  transition: all 0.2s; border: none; text-decoration: none;
}
.btn-primary { background: var(--gold); color: var(--bg-primary); }
.btn-primary:hover { background: var(--gold-dim); color: var(--bg-primary); }
.btn-outline {
  background: transparent; color: var(--text-secondary);
  border: 1px solid var(--border);
}
.btn-outline:hover { border-color: var(--gold); color: var(--text-primary); }

/* --- Cards --- */
.card-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 12px; padding: 28px;
  transition: border-color 0.3s;
}
.card:hover { border-color: var(--gold); }
.card-icon { font-size: 2rem; margin-bottom: 16px; }
.card h3 { margin-bottom: 10px; }
.card p { color: var(--text-muted); font-size: 0.95rem; }

/* --- Metric cards --- */
.metric-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 20px; }
.metric-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 10px; padding: 24px; text-align: center;
}
.metric-value { font-size: 2.2rem; font-weight: 700; color: var(--gold); }
.metric-label { color: var(--text-muted); font-size: 0.85rem; margin-top: 4px; }

/* --- Process Steps --- */
.steps { display: flex; flex-direction: column; gap: 32px; }
.step {
  display: flex; align-items: flex-start; gap: 20px;
}
.step-num {
  background: var(--gold); color: var(--bg-primary);
  font-weight: 700; font-size: 1rem; width: 40px; height: 40px;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  flex-shrink: 0;
}
.step-content h3 { margin-bottom: 6px; }
.step-content p { color: var(--text-muted); font-size: 0.95rem; }

/* --- Section Headers --- */
.section-header { text-align: center; max-width: 600px; margin: 0 auto 48px; }
.section-header p { color: var(--text-muted); margin-top: 12px; }
.section-header .label {
  display: inline-block; color: var(--gold); font-weight: 600;
  font-size: 0.8rem; letter-spacing: 0.1em; text-transform: uppercase;
  margin-bottom: 12px;
}

/* --- CTA Banner --- */
.cta-banner {
  background: var(--bg-card); border: 1px solid var(--gold);
  border-radius: 16px; padding: 48px; text-align: center;
}
.cta-banner h2 { margin-bottom: 12px; }
.cta-banner p { color: var(--text-muted); margin-bottom: 28px; max-width: 500px; margin-left: auto; margin-right: auto; }

/* --- Footer --- */
.footer {
  border-top: 1px solid var(--border); padding: 40px 0;
  color: var(--text-muted); font-size: 0.85rem;
}
.footer .container { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 16px; }
.footer-logo { font-weight: 700; letter-spacing: 0.2em; color: var(--text-secondary); }
.footer-logo .v { color: var(--gold); }
.footer-links { display: flex; gap: 20px; }
.footer-links a { color: var(--text-muted); }
.footer-links a:hover { color: var(--gold); }

/* --- Assessment Tool --- */
.assess-container { max-width: 700px; margin: 0 auto; }
.assess-progress {
  background: var(--border); border-radius: 4px; height: 6px;
  margin-bottom: 32px; overflow: hidden;
}
.assess-progress-bar {
  background: var(--gold); height: 100%; border-radius: 4px;
  transition: width 0.3s ease;
}
.assess-section { display: none; }
.assess-section.active { display: block; }
.assess-question {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 10px; padding: 24px; margin-bottom: 20px;
}
.assess-question label { display: block; font-weight: 600; margin-bottom: 12px; color: var(--text-primary); }
.assess-options { display: flex; flex-wrap: wrap; gap: 10px; }
.assess-opt {
  background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: 8px; padding: 10px 18px; cursor: pointer;
  font-size: 0.9rem; color: var(--text-muted); transition: all 0.2s;
}
.assess-opt:hover { border-color: var(--gold); color: var(--text-secondary); }
.assess-opt.selected { border-color: var(--gold); background: rgba(201, 168, 76, 0.1); color: var(--gold); }
.assess-textarea {
  width: 100%; background: var(--bg-secondary); border: 1px solid var(--border);
  border-radius: 8px; padding: 12px; color: var(--text-secondary);
  font-family: inherit; font-size: 0.95rem; resize: vertical; min-height: 80px;
}
.assess-textarea:focus { outline: none; border-color: var(--gold); }
.assess-nav { display: flex; justify-content: space-between; margin-top: 24px; }

/* Results */
.result-card {
  background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 12px; padding: 28px; margin-bottom: 20px;
}
.result-score {
  font-size: 3rem; font-weight: 700; color: var(--gold);
  text-align: center; margin: 20px 0;
}
.result-bar {
  background: var(--border); border-radius: 4px; height: 10px;
  overflow: hidden; margin: 8px 0;
}
.result-bar-fill { height: 100%; border-radius: 4px; transition: width 0.5s ease; }
.result-high { background: var(--green); }
.result-mid { background: var(--yellow); }
.result-low { background: var(--red); }

/* --- Chat Widget --- */
.chat-trigger {
  position: fixed; bottom: 24px; right: 24px; z-index: 1000;
  background: var(--gold); color: var(--bg-primary);
  width: 56px; height: 56px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  cursor: pointer; border: none; font-size: 1.4rem;
  box-shadow: 0 4px 20px rgba(201, 168, 76, 0.3);
  transition: transform 0.2s;
}
.chat-trigger:hover { transform: scale(1.1); }
.chat-panel {
  position: fixed; bottom: 92px; right: 24px; z-index: 999;
  width: 380px; max-height: 520px;
  background: var(--bg-primary); border: 1px solid var(--border);
  border-radius: 16px; overflow: hidden;
  display: none; flex-direction: column;
  box-shadow: 0 8px 40px rgba(0,0,0,0.5);
}
.chat-panel.open { display: flex; }
.chat-header {
  background: var(--bg-card); padding: 16px 20px;
  border-bottom: 1px solid var(--border);
  display: flex; align-items: center; justify-content: space-between;
}
.chat-header-title { font-weight: 600; color: var(--text-primary); }
.chat-header-sub { font-size: 0.8rem; color: var(--text-muted); }
.chat-close { background: none; border: none; color: var(--text-muted); cursor: pointer; font-size: 1.2rem; }
.chat-messages { flex: 1; overflow-y: auto; padding: 16px 20px; }
.chat-msg {
  margin-bottom: 12px; padding: 10px 14px;
  border-radius: 12px; font-size: 0.9rem; max-width: 85%;
}
.chat-msg-bot { background: var(--bg-card); color: var(--text-secondary); }
.chat-msg-user { background: rgba(201, 168, 76, 0.15); color: var(--text-primary); margin-left: auto; }
.chat-input-area {
  border-top: 1px solid var(--border); padding: 12px 16px;
  display: flex; gap: 8px;
}
.chat-input {
  flex: 1; background: var(--bg-card); border: 1px solid var(--border);
  border-radius: 8px; padding: 10px 14px; color: var(--text-secondary);
  font-family: inherit; font-size: 0.9rem;
}
.chat-input:focus { outline: none; border-color: var(--gold); }
.chat-send {
  background: var(--gold); color: var(--bg-primary); border: none;
  border-radius: 8px; padding: 10px 16px; cursor: pointer;
  font-weight: 600; font-size: 0.85rem;
}

@media (max-width: 480px) {
  .chat-panel { right: 12px; left: 12px; width: auto; bottom: 84px; max-height: 70vh; }
  .chat-trigger { bottom: 16px; right: 16px; }
}

/* --- Utility --- */
.text-gold { color: var(--gold); }
.text-muted { color: var(--text-muted); }
.mt-0 { margin-top: 0; }
.mb-0 { margin-bottom: 0; }
.spacer { height: var(--nav-height); }
