/* ============================================================
   CrewCommander Design System
   Colors: Commander Navy #0C2340, Signal Orange #EE7624
   Fonts: Rajdhani (display), Barlow (body), Barlow Condensed (UI)
   ============================================================ */

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

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

:root {
  --navy: #0C2340;
  --navy-light: #142d4f;
  --navy-dark: #081a30;
  --orange: #EE7624;
  --orange-hover: #d4671e;
  --orange-light: #FFF3E8;
  --white: #ffffff;
  --gray-50: #f9f9f7;
  --gray-100: #f0f0ec;
  --gray-200: #e0e0dc;
  --gray-300: #c0c0b8;
  --gray-400: #999;
  --gray-500: #777;
  --gray-600: #555;
  --gray-700: #333;
  --text: #1a1a1a;
  --font-display: 'Rajdhani', sans-serif;
  --font-body: 'Barlow', sans-serif;
  --font-ui: 'Barlow Condensed', sans-serif;
  --max-width: 1200px;
  --nav-height: 64px;
}

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

body {
  font-family: var(--font-body);
  color: var(--text);
  background: var(--white);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--orange); text-decoration: none; }
a:hover { color: var(--orange-hover); }

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

/* --- Typography --- */
h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 700;
  color: var(--navy);
  text-transform: uppercase;
  letter-spacing: 1.5px;
  line-height: 1.15;
}

h1 { font-size: clamp(2rem, 5vw, 3.5rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.25rem); margin-bottom: 16px; }
h3 { font-size: clamp(1.15rem, 2.5vw, 1.5rem); margin-bottom: 12px; }

p { margin-bottom: 16px; color: var(--gray-600); }
.text-orange { color: var(--orange); }
.text-navy { color: var(--navy); }
.text-white { color: var(--white); }

.subheadline {
  font-family: var(--font-body);
  font-weight: 400;
  font-size: clamp(1rem, 2vw, 1.2rem);
  color: var(--gray-500);
  text-transform: none;
  letter-spacing: 0;
  line-height: 1.5;
  max-width: 640px;
}

/* --- Buttons --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  padding: 14px 32px;
  border-radius: 6px;
  border: none;
  cursor: pointer;
  transition: background 0.2s, transform 0.1s;
  text-decoration: none;
}

.btn:active { transform: scale(0.98); }

.btn-orange {
  background: var(--orange);
  color: var(--white);
}
.btn-orange:hover { background: var(--orange-hover); color: var(--white); }

.btn-white {
  background: var(--white);
  color: var(--navy);
}
.btn-white:hover { background: var(--gray-100); color: var(--navy); }

.btn-outline {
  background: transparent;
  color: var(--white);
  border: 2px solid rgba(255,255,255,0.3);
}
.btn-outline:hover { border-color: var(--white); color: var(--white); }

.btn-navy {
  background: var(--navy);
  color: var(--white);
}
.btn-navy:hover { background: var(--navy-light); color: var(--white); }

.btn-sm { padding: 10px 20px; font-size: 0.85rem; }
.btn-lg { padding: 18px 40px; font-size: 1.1rem; }

/* --- Navigation --- */
.nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--navy);
  height: var(--nav-height);
  display: flex;
  align-items: center;
  border-bottom: 1px solid rgba(255,255,255,0.06);
}

.nav .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
}

.nav-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
}

.nav-logo svg { width: 36px; height: 36px; }

.nav-wordmark {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 16px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: var(--white);
  line-height: 1.1;
}

.nav-wordmark span { color: var(--orange); }

.nav-links {
  display: flex;
  align-items: center;
  gap: 32px;
  list-style: none;
}

.nav-links a {
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 14px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: rgba(255,255,255,0.7);
  transition: color 0.2s;
}

.nav-links a:hover { color: var(--white); }

.nav-cta {
  background: var(--orange);
  color: var(--white) !important;
  padding: 8px 20px;
  border-radius: 5px;
  font-family: var(--font-display) !important;
  font-weight: 700 !important;
  letter-spacing: 1.5px !important;
}

.nav-cta:hover { background: var(--orange-hover); }

/* Mobile nav toggle */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 8px;
}

.nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--white);
  margin: 5px 0;
  transition: 0.3s;
}

/* --- Footer --- */
.footer {
  background: var(--navy);
  color: rgba(255,255,255,0.5);
  padding: 48px 0 32px;
  font-size: 14px;
}

.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr 1fr;
  gap: 40px;
  margin-bottom: 40px;
}

.footer-brand p {
  color: rgba(255,255,255,0.5);
  font-size: 14px;
  line-height: 1.6;
  max-width: 280px;
}

.footer h4 {
  font-size: 13px;
  color: var(--orange);
  margin-bottom: 16px;
  letter-spacing: 2px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  color: rgba(255,255,255,0.5);
  font-size: 14px;
  transition: color 0.2s;
}

.footer-links a:hover { color: var(--white); }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 13px;
}

.footer-tagline {
  font-style: italic;
  color: rgba(255,255,255,0.35);
}

/* --- Section utilities --- */
.section {
  padding: 80px 0;
}

.section-navy {
  background: var(--navy);
  color: var(--white);
}

.section-navy h2, .section-navy h3 { color: var(--white); }
.section-navy p { color: rgba(255,255,255,0.65); }

.section-gray { background: var(--gray-50); }

.section-orange {
  background: var(--orange);
  color: var(--white);
}

.section-orange h2 { color: var(--white); }
.section-orange p { color: rgba(255,255,255,0.85); }

.text-center { text-align: center; }

/* --- CTA Bar --- */
.cta-bar {
  background: var(--orange);
  padding: 48px 0;
  text-align: center;
}

.cta-bar h2 {
  color: var(--white);
  margin-bottom: 24px;
}

.cta-bar .btn-group {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}

/* --- Cards --- */
.card {
  background: var(--white);
  border-radius: 12px;
  padding: 32px;
  box-shadow: 0 2px 16px rgba(12,35,64,0.06);
  transition: transform 0.2s, box-shadow 0.2s;
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 32px rgba(12,35,64,0.1);
}

/* --- Pricing Cards --- */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  max-width: 960px;
  margin: 0 auto;
}

.pricing-card {
  background: var(--white);
  border: 2px solid var(--gray-200);
  border-radius: 12px;
  padding: 36px 28px;
  text-align: center;
  position: relative;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.pricing-card:hover {
  border-color: var(--orange);
  box-shadow: 0 8px 32px rgba(238,118,36,0.12);
}

.pricing-card.featured {
  border-color: var(--orange);
  box-shadow: 0 4px 24px rgba(238,118,36,0.15);
}

.pricing-tier {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--navy);
  margin-bottom: 4px;
}

.pricing-persona {
  font-size: 14px;
  color: var(--gray-500);
  font-style: italic;
  margin-bottom: 16px;
}

.pricing-price {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 48px;
  color: var(--navy);
  line-height: 1;
}

.pricing-price span {
  font-size: 18px;
  font-weight: 500;
  color: var(--gray-400);
}

.pricing-users {
  font-size: 14px;
  color: var(--gray-500);
  margin: 8px 0 24px;
}

.pricing-features {
  list-style: none;
  text-align: left;
  margin-bottom: 28px;
}

.pricing-features li {
  padding: 6px 0;
  font-size: 14px;
  color: var(--gray-600);
  display: flex;
  align-items: center;
  gap: 10px;
}

.pricing-features li::before {
  content: '';
  display: inline-block;
  width: 18px;
  height: 18px;
  background: var(--orange);
  mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M13.5 4.5L6.5 11.5L2.5 7.5' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat;
  -webkit-mask: url("data:image/svg+xml,%3Csvg viewBox='0 0 16 16' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M13.5 4.5L6.5 11.5L2.5 7.5' stroke='white' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat;
  flex-shrink: 0;
}

/* --- Comparison Table --- */
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  margin: 24px 0;
}

.comparison-table thead th {
  background: var(--navy);
  color: var(--white);
  font-family: var(--font-ui);
  font-weight: 600;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 12px 16px;
  text-align: center;
}

.comparison-table thead th:first-child { text-align: left; }

.comparison-table tbody td {
  padding: 14px 16px;
  text-align: center;
  border-bottom: 1px solid var(--gray-200);
}

.comparison-table tbody td:first-child {
  text-align: left;
  font-weight: 600;
  color: var(--navy);
}

.comparison-table tr.cc-row {
  background: var(--orange-light);
  border-top: 3px solid var(--orange);
  border-bottom: 3px solid var(--orange);
}

.comparison-table tr.cc-row td {
  font-weight: 700;
  color: var(--orange);
  font-size: 16px;
}

.comparison-table tr.cc-row td:first-child { color: var(--navy); }

.price-expensive { color: #c0392b; font-weight: 600; }
.price-moderate { color: var(--gray-500); }
.price-savings { display: block; font-size: 11px; font-weight: 400; color: var(--gray-400); text-transform: uppercase; letter-spacing: 0.5px; margin-top: 2px; }

/* --- Feature Grid --- */
.feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 64px;
  align-items: center;
}

.feature-grid.reverse { direction: rtl; }
.feature-grid.reverse > * { direction: ltr; }

.feature-screenshot {
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 8px 40px rgba(12,35,64,0.12);
  background: var(--gray-100);
  aspect-ratio: 16/10;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--gray-400);
  font-size: 14px;
}

.feature-screenshot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* --- Timeline --- */
.timeline {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 16px;
  margin: 40px 0;
}

.timeline-step {
  text-align: center;
  position: relative;
}

.timeline-icon {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: var(--orange);
  color: var(--white);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 20px;
}

.timeline-step h4 {
  font-size: 14px;
  letter-spacing: 1px;
  margin-bottom: 6px;
}

.timeline-step p {
  font-size: 13px;
  line-height: 1.4;
}

/* --- FAQ --- */
.faq-list { max-width: 760px; margin: 0 auto; }

.faq-item {
  border-bottom: 1px solid var(--gray-200);
  padding: 20px 0;
}

.faq-question {
  font-family: var(--font-body);
  font-weight: 600;
  font-size: 16px;
  color: var(--navy);
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: none;
  border: none;
  width: 100%;
  text-align: left;
  padding: 0;
}

.faq-question::after {
  content: '+';
  font-size: 24px;
  color: var(--orange);
  font-weight: 300;
  flex-shrink: 0;
  margin-left: 16px;
  transition: transform 0.2s;
}

.faq-item.open .faq-question::after {
  content: '−';
}

.faq-answer {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.faq-item.open .faq-answer {
  max-height: 500px;
}

.faq-answer p {
  padding-top: 12px;
  font-size: 15px;
}

/* --- Knowledge Cards --- */
.knowledge-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.knowledge-card {
  background: var(--white);
  border-radius: 12px;
  padding: 32px 24px;
  box-shadow: 0 2px 16px rgba(12,35,64,0.06);
}

.knowledge-card h3 {
  font-size: 16px;
  margin-bottom: 12px;
}

.knowledge-card p {
  font-size: 14px;
  line-height: 1.6;
  margin-bottom: 0;
}

/* --- Chat Widget Placeholder --- */
.chat-orb {
  position: fixed;
  bottom: 24px;
  right: 24px;
  width: 60px;
  height: 60px;
  border-radius: 50%;
  background: var(--navy);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 4px 20px rgba(12,35,64,0.3);
  z-index: 200;
  transition: transform 0.2s;
}

.chat-orb:hover { transform: scale(1.08); }

.chat-orb svg { width: 30px; height: 30px; }

/* Pulse animation */
.chat-orb::before {
  content: '';
  position: absolute;
  width: 100%;
  height: 100%;
  border-radius: 50%;
  border: 2px solid var(--orange);
  animation: pulse 2.5s ease-out infinite;
}

@keyframes pulse {
  0% { transform: scale(1); opacity: 0.6; }
  100% { transform: scale(1.6); opacity: 0; }
}

/* ============================================================
   RESPONSIVE
   ============================================================ */

@media (max-width: 900px) {
  .pricing-grid { grid-template-columns: 1fr; max-width: 400px; }
  .feature-grid { grid-template-columns: 1fr; gap: 32px; }
  .feature-grid.reverse { direction: ltr; }
  .knowledge-grid { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .timeline { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-links.open {
    display: flex;
    flex-direction: column;
    position: absolute;
    top: var(--nav-height);
    left: 0;
    right: 0;
    background: var(--navy);
    padding: 24px;
    gap: 20px;
    border-bottom: 2px solid var(--orange);
  }
  .nav-toggle { display: block; }
  .section { padding: 56px 0; }
  .timeline { grid-template-columns: repeat(2, 1fr); }
  .footer-grid { grid-template-columns: 1fr; }
  .footer-bottom { flex-direction: column; gap: 8px; text-align: center; }
  .cta-bar .btn-group { flex-direction: column; align-items: center; }
}

@media (max-width: 480px) {
  .container { padding: 0 16px; }
  .timeline { grid-template-columns: 1fr; }
}
