@import url("https://fonts.googleapis.com/css2?family=Syne:wght@400;500;600;700;800&family=DM+Sans:ital,wght@0,300;0,400;0,500;0,600;1,300&display=swap");

/* =============================================
   DESIGN TOKENS â€” DATE MODULE (ELECTRIC INDIGO)
   ============================================= */
:root {
  --bg: #0a0d14;
  --bg-2: #0f1420;
  --bg-3: #141926;
  --surface: #161c2d;
  --surface-2: #1d2540;
  --surface-3: #222d4a;
  --text-main: #f0f2f8;
  --text-secondary: #8b95b8;
  --text-muted: #5a6480;
  --accent: #6366f1; /* Electric Indigo - Home Screen Theme */
  --accent-2: #818cf8;
  --accent-glow: rgba(99, 102, 241, 0.25);
  --border: rgba(99, 102, 241, 0.12);
  --border-2: rgba(99, 102, 241, 0.22);
  --border-solid: #1e2844;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.4);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.5);
  --shadow-lg: 0 24px 64px rgba(0, 0, 0, 0.6);
  --r-sm: 8px;
  --r: 14px;
  --r-lg: 20px;
  --r-xl: 28px;
  --nav-h: 68px;
  --t: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
  --font-display: 'Syne', sans-serif;
  --font-body: 'DM Sans', sans-serif;
  --max-w: 1400px;
}

[data-theme="light"] {
  --bg: #f5f6fa;
  --bg-2: #eef0f8;
  --bg-3: #e8eaf5;
  --surface: #ffffff;
  --surface-2: #f0f2fc;
  --surface-3: #e6e9f7;
  --text-main: #0d1020;
  --text-secondary: #4a5170;
  --text-muted: #8a90a8;
  --border: rgba(99, 102, 241, 0.1);
  --border-2: rgba(99, 102, 241, 0.2);
  --border-solid: #dde0f0;
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.06);
  --shadow: 0 8px 32px rgba(0, 0, 0, 0.08);
}

/* =============================================
   RESET & BASE
   ============================================= */
*, *::before, *::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text-main);
  line-height: 1.6;
  font-size: 1rem;
  -webkit-font-smoothing: antialiased;
}

a { text-decoration: none; color: inherit; }
button { font-family: inherit; }

.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 2rem 4rem;
}

/* =============================================
   BREADCRUMB
   ============================================= */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 1rem 0;
  font-size: 0.85rem;
  color: var(--text-muted);
  max-width: var(--max-w);
  margin: 0 auto;
  width: 100%;
}

.breadcrumb a {
  color: var(--text-muted);
  transition: var(--t);
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.breadcrumb a:hover { color: var(--accent); }
.breadcrumb i { font-size: 0.75rem; opacity: 0.7; }

.hero-breadcrumb {
  padding-bottom: 0;
  margin-bottom: -0.5rem;
  padding-left: 2rem;
  padding-right: 2rem;
}

/* =============================================
   HERO SECTION
   ============================================= */
.hero-wrapper {
  width: 100%;
  background: var(--bg);
  border-bottom: 1px solid var(--border);
  position: relative;
  overflow: hidden;
}

.hero {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 4rem 2rem;
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  gap: 4rem;
  min-height: auto;
}

.hero-content {
  position: relative;
  z-index: 2;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
  background: var(--accent-glow);
  padding: 0.5rem 1rem;
  border-radius: 99px;
  margin-bottom: 1.5rem;
  border: 1px solid var(--border);
}

.hero-title {
  font-family: var(--font-display);
  font-size: clamp(2.5rem, 5vw, 4rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.02em;
  margin-bottom: 1.5rem;
  color: var(--text-main);
}

.hero-title-accent {
  background: linear-gradient(135deg, var(--accent) 0%, var(--accent-2) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 540px;
  line-height: 1.6;
}

.hero-visual {
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.temporal-scene {
  width: 320px;
  height: 320px;
  position: relative;
  display: flex;
  justify-content: center;
  align-items: center;
}

.temporal-glow {
  position: absolute;
  width: 140%;
  height: 140%;
  background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
  z-index: 0;
  opacity: 0.6;
}

.time-glass {
  width: 100px;
  height: 160px;
  position: relative;
  z-index: 2;
  animation: float 6s ease-in-out infinite;
}

.glass-top, .glass-bottom {
  width: 100%;
  height: 50%;
  background: var(--surface-2);
  border: 4px solid var(--accent);
  position: relative;
}

.glass-top {
  border-bottom: none;
  border-radius: 50% 50% 10% 10% / 100% 100% 10% 10%;
}

.glass-bottom {
  border-top: none;
  border-radius: 10% 10% 50% 50% / 10% 10% 100% 100%;
}

.glass-sand {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 4px;
  height: 60%;
  background: linear-gradient(to bottom, var(--accent), transparent);
  animation: sand-flow 2s linear infinite;
}

@keyframes sand-flow {
  0% { opacity: 0.3; }
  50% { opacity: 1; }
  100% { opacity: 0.3; }
}

.floating-milestones {
  position: absolute;
  width: 100%;
  height: 100%;
  z-index: 3;
}

.milestone {
  position: absolute;
  width: 48px;
  height: 48px;
  background: var(--surface);
  border: 2px solid var(--accent);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  font-size: 1.2rem;
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.3);
  transition: var(--t);
}

.m-1 { top: 10%; left: 10%; animation: float 5s ease-in-out infinite alternate; }
.m-2 { top: 60%; right: 5%; animation: float 7s ease-in-out infinite alternate-reverse; }
.m-3 { bottom: 15%; left: 20%; animation: float 6s ease-in-out infinite alternate 1s; }

.orbit-ring {
  position: absolute;
  width: 240px;
  height: 240px;
  border: 2px dashed var(--border-2);
  border-radius: 50%;
  animation: rotate 20s linear infinite;
  opacity: 0.4;
}

@keyframes rotate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@keyframes float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-15px); }
}

/* =============================================
   CATEGORY SECTION
   ============================================= */
.category-title {
  display: flex;
  align-items: center;
  font-family: var(--font-display);
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 1.25rem;
  margin-top: 1rem;
  gap: 0.7rem;
  line-height: 1.2;
  background: var(--surface);
  border-left: 6px solid var(--accent);
  border-radius: 0 var(--r-sm) var(--r-sm) 0;
  padding: 0.6rem 1.2rem;
  box-shadow: 0 2px 8px -4px var(--accent-glow);
}

.calc-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 1.5rem;
  margin-bottom: 4rem;
}

.calc-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 1.75rem;
  text-decoration: none;
  transition: var(--t);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  position: relative;
  overflow: hidden;
}

.calc-card::after {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(135deg, var(--accent) 0%, transparent 100%);
  opacity: 0;
  transition: var(--t);
}

.calc-card:hover {
  transform: translateY(-5px);
  border-color: var(--accent);
  box-shadow: var(--shadow-lg);
}

.calc-card:hover::after { opacity: 0.05; }

.category-icon {
  width: 48px;
  height: 48px;
  background: var(--accent-glow);
  color: var(--accent);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  margin-bottom: 0.5rem;
  transition: var(--t);
}

.calc-card:hover .category-icon {
  background: var(--accent);
  color: white;
  transform: translateY(-8px);
  box-shadow: 0 12px 24px var(--accent-glow);
}

.calc-card h3 {
  font-family: var(--font-display);
  font-size: 1.2rem;
  font-weight: 700;
  color: var(--text-main);
  transition: var(--t);
}

.calc-card:hover h3 { color: var(--accent-2); }

.calc-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.card-arrow {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--bg-3);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    color: var(--text-muted);
    transition: var(--t);
    align-self: flex-end;
    border: 1px solid var(--border-solid);
    margin-top: auto;
}

.calc-card:hover .card-arrow {
    background: var(--accent);
    color: white;
    border-color: var(--accent);
    transform: translateX(3px);
    box-shadow: 0 4px 12px var(--accent-glow);
}

/* =============================================
   RESPONSIVE
   ============================================= */
@media (max-width: 1200px) {
  .hero {
    grid-template-columns: 1fr;
    text-align: center;
    padding: 3.5rem 1.5rem;
  }
  .hero-content { margin: 0 auto; max-width: 800px; }
  .hero-eyebrow, .breadcrumb { justify-content: center; }
  .hero-visual { display: none; }
}

@media (min-width: 1201px) {
  .hero-breadcrumb {
    padding-left: calc(2rem + 3vw);
  }
}

@media (min-width: 1401px) {
  :root {
    --max-w: 1600px;
  }
  .hero {
    padding: 0.75rem 2rem;
  }
  .breadcrumb {
    padding: 0.5rem 0;
  }
  .hero-breadcrumb {
    padding-left: 4rem;
  }
  .calc-grid {
    grid-template-columns: repeat(6, 1fr) !important;
    gap: 2rem !important;
  }
  .calc-card:nth-child(1), .calc-card:nth-child(2), .calc-card:nth-child(3) {
    grid-column: span 2;
  }
  .calc-card:nth-child(4), .calc-card:nth-child(5) {
    grid-column: span 3;
  }
  .calc-card .card-content p {
    font-size: 1.05rem;
    max-width: 90%;
  }
}

@media (max-width: 640px) {
  .container { padding: 0 0.35rem 3rem !important; }
  .breadcrumb { width: 92%; max-width: 92%; margin: 0 auto; font-size: 0.7rem; padding-top: 1rem; text-align: left; justify-content: flex-start; }
  .hero { padding: 1.25rem 0; width: 92%; max-width: 92%; margin: 0 auto; text-align: left; }
  .hero-content { text-align: left; }
  .hero-eyebrow { justify-content: flex-start; }
  .hero-title { font-size: clamp(1.8rem, 8vw, 2.5rem); text-align: left; }
  .hero-subtitle { text-align: left; font-size: 0.9rem; }
  
  .calc-grid { grid-template-columns: 1fr; gap: 1rem; }
  .calc-card {
    display: grid;
    grid-template-columns: auto 1fr auto;
    grid-template-areas: "icon title arrow" "desc desc desc";
    gap: 0.5rem 1rem;
    padding: 1.25rem;
  }
  .category-icon { grid-area: icon; width: 42px; height: 42px; font-size: 1.2rem; margin-bottom: 0; }
  .calc-card h3 { grid-area: title; font-size: 1.1rem; align-self: center; }
  .card-arrow { grid-area: arrow; align-self: center; margin-top: 0; }
  .calc-card p { grid-area: desc; font-size: 0.85rem; }
}

/* Tool styles */
.tool-container {
    max-width: 800px;
    margin: 2rem auto;
    background: var(--surface);
    border: 1px solid var(--border-solid);
    border-radius: var(--r-lg);
    padding: 2.5rem;
    box-shadow: var(--shadow);
}

.input-group { margin-bottom: 1.5rem; position: relative; }
.input-label { display: block; font-size: 0.9rem; font-weight: 600; color: var(--text-secondary); margin-bottom: 0.6rem; }
.input-field {
    width: 100%;
    height: 52px;
    padding: 0 1.25rem;
    background: var(--bg-2);
    border: 1px solid var(--border-solid);
    border-radius: var(--r);
    color: var(--text-main);
    font-size: 1rem;
    transition: var(--t);
}
.input-field:focus { border-color: var(--accent); background: var(--surface-2); box-shadow: 0 0 0 4px var(--accent-glow); outline: none; }

.btn-calculate {
    width: 100%;
    height: 56px;
    background: var(--accent);
    color: white;
    border: none;
    border-radius: var(--r);
    font-size: 1.1rem;
    font-weight: 700;
    cursor: pointer;
    transition: var(--t);
    margin-top: 1rem;
    box-shadow: 0 4px 15px var(--accent-glow);
}
.btn-calculate:hover { transform: translateY(-2px); background: var(--accent-2); box-shadow: 0 8px 25px var(--accent-glow); }

.result-box {
    margin-top: 2.5rem;
    padding: 2rem;
    background: var(--bg-2);
    border: 1px solid var(--border-solid);
    border-radius: var(--r);
    text-align: center;
}
.result-label { font-size: 0.85rem; font-weight: 700; text-transform: uppercase; color: var(--accent); letter-spacing: 0.1em; margin-bottom: 0.5rem; display: block; }
.result-value { font-size: 3rem; font-weight: 800; color: var(--text-main); line-height: 1; }

/* Back to Top */
.scroll-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 48px;
    height: 48px;
    background: var(--accent);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2rem;
    cursor: pointer;
    transition: var(--t);
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    box-shadow: 0 4px 15px var(--accent-glow);
    border: none;
}
.scroll-top.visible { opacity: 1; visibility: visible; }
.scroll-top:hover { transform: translateY(-5px); background: var(--accent-2); }

/* =============================================
   ULTRA-MOBILE OPTIMIZATION (STUNNING AESTHETICS)
   ============================================= */
@media (max-width: 500px) {
    /* HERO TITLE - Maximum Impact */
    h1, .hero-title, .card-title, .hero-title span { font-size: 2.1rem !important; letter-spacing: -0.03em !important; line-height: 1.1 !important; }
    .hero-subtitle { font-size: 1.05rem !important; line-height: 1.6 !important; opacity: 1; }
    .hero-eyebrow { font-size: 0.9rem !important; font-weight: 700 !important; }

    /* Other Typography (Balanced) */
    h2, .section-title, .category-title { font-size: 1.4rem !important; letter-spacing: -0.01em !important; }
    h3 { font-size: 1.2rem !important; }
    h4 { font-size: 1.05rem !important; }
    p, .footer-brand p, .calc-card p, .card-desc { font-size: 0.9rem !important; line-height: 1.6 !important; opacity: 1; }
    a, .nav-links a, .footer-col a, label, .input-label, .form-label, span, .breadcrumb { font-size: 0.85rem !important; }

    /* Spacing & Layout Optimization */
    .container, .navbar-inner, .hero, .footer-inner, .faq-section-wrap, .tool-container, .card {
        padding-left: 1rem !important;
        padding-right: 1rem !important;
        max-width: 100% !important;
        width: 100% !important;
        margin-left: 0 !important;
        margin-right: 0 !important;
    }

    .hero { padding-top: 2rem !important; padding-bottom: 2rem !important; min-height: auto !important; }
    .calc-grid, .grid, .calc-form { gap: 1rem !important; }
    .form-group { gap: 0.4rem !important; }
    
    /* Card & Component Refinement */
    .calc-card, .card, .tool-container, .result-box, .result-main, .result-item {
        padding: 1rem !important;
        border-radius: 14px !important;
        margin-bottom: 0.85rem !important;
    }
    
    .card-header { margin-bottom: 1.25rem !important; }
    .result-box { margin-top: 1.5rem !important; padding-top: 1.5rem !important; }

    /* Form Elements */
    .input-field, .search-bar, select {
        height: 44px !important;
        font-size: 0.95rem !important;
        padding: 0 0.85rem !important;
        border-radius: 10px !important;
    }

    .btn-primary, .btn-ghost, .btn-calculate, .btn-premium {
        height: 46px !important;
        padding: 0 1.25rem !important;
        font-size: 0.95rem !important;
        border-radius: 10px !important;
        width: 100% !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        margin-top: 0.4rem !important;
    }

    /* Icon & Visual Scaling */
    .category-icon, .card-icon-wrap, .logo-icon, .divider-icon-box, .feature-icon-wrap, .step-num {
        width: 36px !important;
        height: 36px !important;
        min-width: 36px !important;
        font-size: 1rem !important;
    }
    
    .logo-text { font-size: 1.1rem !important; }
    
    /* Result Specifics */
    .result-value { font-size: 2.2rem !important; }
    .result-label, .res-label { font-size: 0.75rem !important; }
}

