/* ===========================================
   ASCOA Proposal - Global Styles
   =========================================== */

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

/* --- CSS Custom Properties --- */
:root {
  --bg: #f1f8f7;
  --fg: #0f2b2a;
  --card: #f8fcfb;
  --card-fg: #0f2b2a;
  --primary: #0e7367;
  --primary-fg: #f1fcfa;
  --secondary: #e0f2ed;
  --secondary-fg: #0f3d38;
  --muted: #e4f0ed;
  --muted-fg: #4a7872;
  --accent: #1a8c5a;
  --accent-fg: #f1fcfa;
  --border: #c8e0da;
  --ocean-deep: #0c2e34;
  --ocean-medium: #134a52;
  --sand: #f0e8d8;
  --coral: #d45a3a;
  --radius: 0.625rem;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-serif: 'Playfair Display', Georgia, serif;
}

/* --- Reset & Base --- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--fg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; }
ul, ol { list-style: none; }

/* --- Utility Classes --- */
.container { max-width: 1200px; margin: 0 auto; padding: 0 1.5rem; }
.container-sm { max-width: 900px; margin: 0 auto; padding: 0 1.5rem; }
.container-lg { max-width: 1400px; margin: 0 auto; padding: 0 1.5rem; }
.text-center { text-align: center; }
.text-balance { text-wrap: balance; }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }

/* --- Typography --- */
.font-serif { font-family: var(--font-serif); }
.heading-xl { font-family: var(--font-serif); font-size: clamp(2.25rem, 5vw, 3.75rem); font-weight: 700; line-height: 1.1; letter-spacing: -0.02em; }
.heading-lg { font-family: var(--font-serif); font-size: clamp(1.75rem, 3.5vw, 2.5rem); font-weight: 700; line-height: 1.2; }
.heading-md { font-family: var(--font-serif); font-size: clamp(1.25rem, 2.5vw, 1.75rem); font-weight: 700; line-height: 1.3; }
.label-sm { font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.1em; }
.text-lg { font-size: 1.125rem; line-height: 1.7; }
.text-sm { font-size: 0.875rem; line-height: 1.6; }
.text-xs { font-size: 0.75rem; line-height: 1.5; }

/* --- Colors --- */
.text-primary { color: var(--primary); }
.text-accent { color: var(--accent); }
.text-muted { color: var(--muted-fg); }
.text-coral { color: var(--coral); }
.text-light { color: rgba(241,252,250,.8); }
.text-light-60 { color: rgba(241,252,250,.6); }
.text-light-40 { color: rgba(241,252,250,.4); }
.bg-card { background: var(--card); }
.bg-muted { background: var(--muted); }
.bg-ocean-deep { background: var(--ocean-deep); }
.bg-ocean-medium { background: var(--ocean-medium); }
.bg-sand { background: var(--sand); }

/* --- Sections --- */
.section { padding: 5rem 0; }
.section-sm { padding: 3rem 0; }
@media (min-width: 768px) { .section { padding: 7rem 0; } }

/* --- Buttons --- */
.btn {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.75rem 1.5rem; border-radius: var(--radius);
  font-size: 0.875rem; font-weight: 600;
  transition: all 0.2s ease;
}
.btn-primary { background: var(--primary); color: var(--primary-fg); }
.btn-primary:hover { opacity: 0.9; }
.btn-accent { background: var(--accent); color: var(--accent-fg); }
.btn-accent:hover { opacity: 0.9; }
.btn-outline {
  background: transparent; color: var(--primary-fg);
  border: 1px solid rgba(241,252,250,.3);
}
.btn-outline:hover { background: rgba(241,252,250,.1); }
.btn-outline-accent {
  background: rgba(26,140,90,.1); color: var(--accent);
  border: 1px solid var(--accent);
}
.btn-outline-accent:hover { background: var(--accent); color: var(--accent-fg); }
.btn-lg { padding: 0.875rem 2rem; }
.btn-block { width: 100%; justify-content: center; }

/* --- Cards --- */
.card {
  background: var(--card); border: 1px solid var(--border);
  border-radius: 0.75rem; padding: 1.5rem;
  transition: all 0.2s ease;
}
.card:hover { box-shadow: 0 4px 20px rgba(0,0,0,.06); }
.card-glass {
  background: rgba(241,252,250,.05); border: 1px solid rgba(241,252,250,.1);
  border-radius: 0.75rem; padding: 2rem;
  backdrop-filter: blur(8px);
}

/* --- Grid Layouts --- */
.grid { display: grid; gap: 1.5rem; }
.grid-2 { grid-template-columns: 1fr; }
.grid-3 { grid-template-columns: 1fr; }
.grid-4 { grid-template-columns: repeat(2, 1fr); }
@media (min-width: 640px) { .grid-2 { grid-template-columns: repeat(2, 1fr); } .grid-3 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }

/* --- Flex --- */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-1 { gap: 0.25rem; }
.gap-2 { gap: 0.5rem; }
.gap-3 { gap: 0.75rem; }
.gap-4 { gap: 1rem; }
.gap-6 { gap: 1.5rem; }
.gap-8 { gap: 2rem; }
.gap-10 { gap: 2.5rem; }

/* --- Hero with Background Image --- */
.hero-bg {
  position: relative; overflow: hidden;
}
.hero-bg .hero-img {
  position: absolute; inset: 0;
  width: 100%; height: 100%;
  object-fit: cover; opacity: 0.35;
}
.hero-bg .hero-overlay {
  position: absolute; inset: 0;
  background: linear-gradient(to bottom, rgba(12,46,52,.8), rgba(12,46,52,.5), rgba(12,46,52,.9));
}
.hero-bg .hero-content { position: relative; z-index: 1; }

/* --- Icon container --- */
.icon-box {
  display: flex; align-items: center; justify-content: center;
  width: 3rem; height: 3rem; border-radius: 0.5rem;
  flex-shrink: 0;
}
.icon-box-lg { width: 3.5rem; height: 3.5rem; }
.icon-box-sm { width: 2.25rem; height: 2.25rem; }
.icon-box-circle { border-radius: 50%; }
.icon-box-primary { background: rgba(14,115,103,.1); color: var(--primary); }
.icon-box-accent { background: rgba(26,140,90,.1); color: var(--accent); }
.icon-box-accent-dark { background: rgba(26,140,90,.2); color: var(--accent); }

/* --- Stat bar --- */
.stat-bar {
  position: relative; border-top: 1px solid rgba(241,252,250,.1);
  background: rgba(12,46,52,.8); backdrop-filter: blur(8px);
}

/* --- Badge / Tag --- */
.badge {
  display: inline-flex; align-items: center; gap: 0.5rem;
  padding: 0.375rem 1rem; border-radius: 9999px;
  font-size: 0.75rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.08em;
}
.badge-accent { background: rgba(26,140,90,.1); border: 1px solid rgba(26,140,90,.3); color: var(--accent); }
.badge-dot { width: 0.5rem; height: 0.5rem; border-radius: 50%; background: var(--accent); }
.tag {
  display: inline-flex; padding: 0.5rem 1rem; border-radius: 0.5rem;
  border: 1px solid var(--border); background: var(--card);
  font-size: 0.875rem; font-weight: 500; color: var(--fg);
  transition: all 0.2s;
}
.tag:hover { border-color: rgba(14,115,103,.3); background: rgba(14,115,103,.05); }

/* --- Session type badges --- */
.session-badge {
  display: inline-flex; padding: 0.25rem 0.75rem; border-radius: 9999px;
  font-size: 0.75rem; font-weight: 500;
}
.session-keynote { background: rgba(14,115,103,.1); color: var(--primary); }
.session-panel { background: rgba(26,140,90,.1); color: var(--accent); }
.session-workshop { background: rgba(212,90,58,.1); color: var(--coral); }
.session-presentation { background: rgba(19,74,82,.1); color: var(--ocean-medium); }
.session-ceremony { background: var(--sand); color: var(--fg); }
.session-social { background: rgba(26,140,90,.1); color: var(--accent); }

/* --- Issue severity cards --- */
.issue-high { border-color: #dc2626; background: rgba(220,38,38,.04); }
.issue-medium { border-color: var(--coral); background: rgba(212,90,58,.04); }
.issue-low { border-color: var(--muted-fg); background: rgba(74,120,114,.04); }
.severity-badge {
  display: inline-flex; padding: 0.125rem 0.625rem; border-radius: 9999px;
  font-size: 0.75rem; font-weight: 500; background: var(--card);
  color: var(--muted-fg); margin-left: auto;
}

/* --- Speaker card --- */
.speaker-avatar {
  width: 4rem; height: 4rem; border-radius: 50%;
  background: rgba(14,115,103,.1); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 1.125rem; font-weight: 700;
}

/* --- Pricing highlight --- */
.pricing-popular {
  border: 2px solid var(--accent); background: rgba(26,140,90,.05);
}
.pricing-popular-badge {
  position: absolute; top: -0.75rem; left: 50%; transform: translateX(-50%);
  background: var(--accent); color: var(--accent-fg);
  padding: 0.25rem 1rem; border-radius: 9999px;
  font-size: 0.75rem; font-weight: 600;
}

/* --- Section heading --- */
.section-heading { margin-bottom: 2rem; padding-bottom: 1.5rem; border-bottom: 1px solid var(--border); }

/* --- Tab buttons --- */
.tab-btn {
  padding: 0.625rem 1.25rem; border-radius: 0.5rem;
  font-size: 0.875rem; font-weight: 500;
  background: var(--muted); color: var(--muted-fg);
  transition: all 0.2s;
}
.tab-btn:hover { opacity: 0.8; }
.tab-btn.active { background: var(--primary); color: var(--primary-fg); }

/* --- Image overlay --- */
.img-overlay-container { position: relative; overflow: hidden; border-radius: 1rem; }
.img-overlay-container img { width: 100%; height: 100%; object-fit: cover; aspect-ratio: 4/3; }
.img-overlay-caption {
  position: absolute; bottom: 0; left: 0; right: 0;
  background: linear-gradient(to top, rgba(12,46,52,.8), transparent);
  padding: 1.5rem;
}

/* --- Sticky Navbar --- */
.navbar {
  position: sticky; top: 0; z-index: 50;
  border-bottom: 1px solid rgba(200,224,218,.5);
  background: rgba(248,252,251,.95); backdrop-filter: blur(12px);
}
.nav-link {
  padding: 0.5rem 0.75rem; border-radius: 0.375rem;
  font-size: 0.875rem; font-weight: 500; color: var(--muted-fg);
  transition: all 0.15s;
}
.nav-link:hover { background: var(--muted); color: var(--fg); }

/* --- Back banner --- */
.back-banner {
  background: var(--ocean-deep); padding: 0.5rem 1.5rem; text-align: center;
}
.back-banner a {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.75rem; font-weight: 500; color: rgba(241,252,250,.7);
  transition: color 0.2s;
}
.back-banner a:hover { color: var(--primary-fg); }
.back-banner .proto-badge {
  background: rgba(26,140,90,.2); color: var(--accent);
  padding: 0.125rem 0.5rem; border-radius: 0.25rem;
}

/* --- Mobile menu --- */
.mobile-menu { display: none; border-top: 1px solid var(--border); background: var(--card); padding: 1rem 1.5rem; }
.mobile-menu.open { display: block; }
@media (min-width: 1024px) { .mobile-menu { display: none !important; } .desktop-only { display: flex !important; } .mobile-toggle { display: none !important; } }
@media (max-width: 1023px) { .desktop-only { display: none !important; } }

/* --- Footer --- */
.footer { background: var(--ocean-deep); padding: 4rem 0; }
.footer-grid { display: grid; gap: 3rem; grid-template-columns: 1fr; }
@media (min-width: 768px) { .footer-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .footer-grid { grid-template-columns: repeat(4, 1fr); } }
.footer a { font-size: 0.875rem; color: rgba(241,252,250,.6); transition: color 0.2s; }
.footer a:hover { color: var(--accent); }

/* --- Responsive image fill --- */
.aspect-43 { aspect-ratio: 4/3; }
.aspect-1610 { aspect-ratio: 16/10; }
.object-cover { object-fit: cover; width: 100%; height: 100%; }

/* --- Proposal TOC --- */
.toc-item {
  display: flex; align-items: center; gap: 0.75rem;
}
.toc-number {
  display: flex; align-items: center; justify-content: center;
  width: 1.5rem; height: 1.5rem; border-radius: 50%;
  background: rgba(14,115,103,.1); color: var(--primary);
  font-size: 0.75rem; font-weight: 700; flex-shrink: 0;
}

/* --- Arrow links --- */
.arrow-link {
  display: inline-flex; align-items: center; gap: 0.5rem;
  font-size: 0.875rem; font-weight: 500;
  transition: gap 0.2s;
}
.arrow-link:hover { gap: 0.75rem; }

/* --- Highlight box --- */
.highlight-box {
  border-radius: 0.5rem; padding: 1.25rem;
}
.highlight-primary { border: 1px solid rgba(14,115,103,.2); background: rgba(14,115,103,.05); }

/* --- SVG Icons inline --- */
.icon { width: 1rem; height: 1rem; flex-shrink: 0; }
.icon-lg { width: 1.25rem; height: 1.25rem; }
.icon-xl { width: 1.5rem; height: 1.5rem; }
.icon-xxl { width: 1.75rem; height: 1.75rem; }
