/* styles.css - MODERN GLASS DARK & ORANGE THEME */

/* --- 1. FONTS & BASICS --- */
@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@300;400;600;800&family=JetBrains+Mono:wght@400;700&display=swap');

:root {
  --bg-color: #0f1115;      /* Deep void dark */
  --card-bg: rgba(30, 35, 45, 0.4); /* Glass tile base */
  --text-main: #e2e8f0;     /* Soft white */
  --text-muted: #94a3b8;    /* Muted grey */
  --accent: #F28C3D;        /* The Orange Brand */
  --accent-glow: rgba(242, 140, 61, 0.3);
  --border-color: rgba(255, 255, 255, 0.1);
}

body {
  background-color: var(--bg-color) !important;
  color: var(--text-main);
  font-family: 'Outfit', sans-serif;
  font-weight: 300;
  line-height: 1.7;
}

h1, h2, h3, h4, h5, h6 {
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #fff; /* Crisp white headers usually, accented below */
  margin-top: 2.5rem;
}

h1, .title, .navbar-brand {
    background: linear-gradient(135deg, #fff 30%, var(--accent) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

code, pre {
    font-family: 'JetBrains Mono', monospace;
}

/* --- 2. GLASSMORPHISM NAVBAR --- */
.navbar {
  background: rgba(15, 17, 21, 0.75) !important; /* Semi-transparent */
  backdrop-filter: blur(12px); /* Blur effect */
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border-color);
  padding-top: 1rem;
  padding-bottom: 1rem;
}

.navbar-brand {
  font-family: 'Outfit', sans-serif;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  font-size: 1.1rem;
  white-space: normal; /* Allow text to wrap if needed, or at least don't truncate with ... */
  overflow: visible;
  max-width: none;
}

.navbar-nav .nav-link {
  color: var(--text-muted) !important;
  font-weight: 600;
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
  margin: 0 5px;
}

.navbar-nav .nav-link:hover, .navbar-nav .nav-link.active {
  color: var(--accent) !important;
  text-shadow: 0 0 10px var(--accent-glow);
}

/* Icons in navbar */
.navbar-nav i {
    color: inherit; /* Follows link color */
}

/* --- 3. PREMIUM CARDS & CONTAINERS --- */
/* Replacing standard Quarto/Bootstrap cards with glass look */
/* The below selector was empty, removed to fix lint error */
/* .card, .callout, .g-col-4, .g-col-6, .g-col-12 {} */

/* Custom Glass Class for specific divs */
.glass-card {
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(5px);
    border-radius: 12px;
    padding: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px -10px rgba(0,0,0,0.5);
    border-color: rgba(242, 140, 61, 0.3); /* Subtle orange border on hover */
}

/* --- 4. BUTTONS --- */
.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, #d46b1f 100%) !important;
  border: none !important;
  color: #000 !important;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 12px 30px;
  border-radius: 6px;
  box-shadow: 0 4px 15px var(--accent-glow);
  transition: all 0.3s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px var(--accent-glow);
}

.btn-outline-primary {
    border: 1px solid var(--accent) !important;
    background: transparent !important;
    color: var(--accent) !important;
    font-weight: 700;
    text-transform: uppercase;
    padding: 12px 30px;
}
.btn-outline-primary:hover {
    background: var(--accent) !important;
    color: #000 !important;
}

/* Emerald Green CTA */
.btn-cta {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important; /* Emerald 500 -> 600 */
    border: none !important;
    color: #fff !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 30px;
    border-radius: 6px;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
    transition: all 0.3s ease;
}

.btn-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
    background: linear-gradient(135deg, #34d399 0%, #059669 100%) !important;
}

/* Indigo Button (Veloz Brand) */
.btn-indigo {
    background: linear-gradient(135deg, #4F46E5 0%, #4338ca 100%) !important; /* Veloz Brand: #4F46E5 */
    border: none !important;
    color: #fff !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 30px;
    border-radius: 6px;
    box-shadow: 0 4px 15px rgba(79, 70, 229, 0.4);
    transition: all 0.3s ease;
}

.btn-indigo:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(79, 70, 229, 0.5);
    background: linear-gradient(135deg, #818cf8 0%, #4338ca 100%) !important;
}

.btn-outline-indigo {
    border: 1px solid #4F46E5 !important;
    background: transparent !important;
    color: #4F46E5 !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 30px;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.btn-outline-indigo:hover {
    background: #4F46E5 !important;
    color: white !important;
    box-shadow: 0 4px 15px rgba(79, 70, 229, 0.4);
    transform: translateY(-2px);
}

/* Gradient Headers for Cards */
.glass-card h3 {
    background: linear-gradient(135deg, #fff 30%, var(--accent) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
    margin-top: 0; /* Tighten up spacing */
}


/* --- 5. ANIMATIONS --- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

main.content {
    animation: fadeIn 0.8s ease-out forwards;
}

/* --- 6. PAGE SPECIFIC TWEAKS --- */

/* Sidebar "On this page" text */
#quarto-margin-sidebar h2 {
  color: var(--text-muted);
  font-size: 0.85rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-top: 0;
}

/* TOC Links */
#TOC ul li a {
  color: #64748b !important;
}
#TOC ul li a:hover, #TOC ul li a.active {
  color: var(--accent) !important;
  border-left-color: var(--accent) !important;
}

/* Links in body */
a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.2s;
}
a:hover {
  color: #ffdcb5;
  text-decoration: underline;
}

/* Footer */
footer {
  margin-top: 100px;
  padding: 50px 0;
  border-top: 1px solid var(--border-color);
  background: #0b0c0f !important;
  color: #555;
  text-align: center;
  font-size: 0.9rem;
}

/* Profile Image */
.about-image {
  border: 2px solid var(--accent);
  box-shadow: 0 0 20px var(--accent-glow);
  border-radius: 50%; /* Modern circle or rounded? Quarto usually defaults circle for jolla */
  filter: grayscale(100%);
  transition: filter 0.5s ease;
}
.about-image:hover {
    filter: grayscale(0%);
}

/* --- 7. HELPER UTILITIES --- */
.text-accent {
    color: var(--accent) !important;
}

.hero-header {
    font-size: 4rem; /* Increased from 3.5rem for better contrast */
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.lead, .hero-section p {
    font-size: 1.35rem; /* Explicitly set size, not too big */
    color: var(--text-muted);
    background: var(--card-bg);
    border: 1px solid var(--border-color);
    backdrop-filter: blur(5px);
    border-radius: 12px;
    padding: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.glass-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px -10px rgba(0,0,0,0.5);
    border-color: rgba(242, 140, 61, 0.3); /* Subtle orange border on hover */
}

/* --- 4. BUTTONS --- */
.btn-primary {
  background: linear-gradient(135deg, var(--accent) 0%, #d46b1f 100%) !important;
  border: none !important;
  color: #000 !important;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  padding: 12px 30px;
  border-radius: 6px;
  box-shadow: 0 4px 15px var(--accent-glow);
  transition: all 0.3s ease;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 25px var(--accent-glow);
}

.btn-outline-primary {
    border: 1px solid var(--accent) !important;
    background: transparent !important;
    color: var(--accent) !important;
    font-weight: 700;
    text-transform: uppercase;
    padding: 12px 30px;
}
.btn-outline-primary:hover {
    background: var(--accent) !important;
    color: #000 !important;
}

/* Emerald Green CTA */
.btn-cta {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%) !important; /* Emerald 500 -> 600 */
    border: none !important;
    color: #fff !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 30px;
    border-radius: 6px;
    box-shadow: 0 4px 15px rgba(16, 185, 129, 0.4);
    transition: all 0.3s ease;
}

.btn-cta:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.5);
    background: linear-gradient(135deg, #34d399 0%, #059669 100%) !important;
}

/* Indigo Button (Veloz Brand) */
.btn-indigo {
    background: linear-gradient(135deg, #4F46E5 0%, #4338ca 100%) !important; /* Veloz Brand: #4F46E5 */
    border: none !important;
    color: #fff !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 30px;
    border-radius: 6px;
    box-shadow: 0 4px 15px rgba(79, 70, 229, 0.4);
    transition: all 0.3s ease;
}

.btn-indigo:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(79, 70, 229, 0.5);
    background: linear-gradient(135deg, #818cf8 0%, #4338ca 100%) !important;
}

.btn-outline-indigo {
    border: 1px solid #4F46E5 !important;
    background: transparent !important;
    color: #4F46E5 !important;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    padding: 12px 30px;
    border-radius: 6px;
    transition: all 0.3s ease;
}

.btn-outline-indigo:hover {
    background: #4F46E5 !important;
    color: white !important;
    box-shadow: 0 4px 15px rgba(79, 70, 229, 0.4);
    transform: translateY(-2px);
}

/* Gradient Headers for Cards */
.glass-card h3 {
    background: linear-gradient(135deg, #fff 30%, var(--accent) 100%);
    background-clip: text;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
    margin-top: 0; /* Tighten up spacing */
}


/* --- 5. ANIMATIONS --- */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

main.content {
    animation: fadeIn 0.8s ease-out forwards;
}

/* --- 6. PAGE SPECIFIC TWEAKS --- */

/* Sidebar "On this page" text */
#quarto-margin-sidebar h2 {
  color: var(--text-muted);
  font-size: 0.85rem;
  letter-spacing: 1px;
  text-transform: uppercase;
  margin-top: 0;
}

/* TOC Links */
#TOC ul li a {
  color: #64748b !important;
}
#TOC ul li a:hover, #TOC ul li a.active {
  color: var(--accent) !important;
  border-left-color: var(--accent) !important;
}

/* Links in body */
a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
  transition: all 0.2s;
}
a:hover {
  color: #ffdcb5;
  text-decoration: underline;
}

/* Footer */
footer {
  margin-top: 100px;
  padding: 50px 0;
  border-top: 1px solid var(--border-color);
  background: #0b0c0f !important;
  color: #555;
  text-align: center;
  font-size: 0.9rem;
}

/* Profile Image */
.about-image {
  border: 2px solid var(--accent);
  box-shadow: 0 0 20px var(--accent-glow);
  border-radius: 50%; /* Modern circle or rounded? Quarto usually defaults circle for jolla */
  filter: grayscale(100%);
  transition: filter 0.5s ease;
}
.about-image:hover {
    filter: grayscale(0%);
}

/* --- 7. HELPER UTILITIES --- */
.text-accent {
    color: var(--accent) !important;
}

.hero-header {
    font-size: 4rem; /* Increased from 3.5rem for better contrast */
    line-height: 1.1;
    margin-bottom: 1.5rem;
}

.lead, .hero-section p {
    font-size: 1.35rem; /* Explicitly set size, not too big */
    color: var(--text-muted);
    font-weight: 300;
    line-height: 1.6;
}

/* --- 8. MOBILE NAV FIX (2-Column Grid) --- */
/* --- 8. MOBILE NAV FIX (Unified Stack) --- */
@media (max-width: 991.98px) {
  .navbar-collapse {
      background: rgba(15, 17, 21, 0.98);
      backdrop-filter: blur(20px);
      padding: 20px;
      border-bottom: 1px solid rgba(255,255,255,0.1);
      border-top: 1px solid rgba(255,255,255,0.05);
      margin-top: 10px;
      max-height: 85vh;
      overflow-y: auto;
  }
  
  .navbar-nav {
      display: flex !important;
      flex-direction: column !important;
      gap: 12px;
  }
  
  /* Universal Glass Button Style for ALL items */
  .navbar-nav .nav-item,
  .navbar-nav .dropdown {
      display: block !important;
      width: 100% !important;
      background: rgba(255,255,255,0.04);
      border: 1px solid rgba(255,255,255,0.05);
      border-radius: 10px;
      text-align: center;
      transition: all 0.2s ease;
      margin: 0;
  }
  
  .navbar-nav .nav-item:hover,
  .navbar-nav .dropdown:hover {
      background: rgba(255,255,255,0.1);
      border-color: rgba(255,255,255,0.2);
      transform: translateY(-2px);
  }

  /* Link Text Styling */
  .navbar-nav .nav-link,
  .navbar-nav .dropdown-toggle {
      width: 100%;
      padding: 15px 0 !important;
      font-size: 1rem !important;
      font-weight: 600;
      letter-spacing: 0.5px;
      color: var(--text-main) !important;
      display: flex;
      justify-content: center;
      align-items: center;
      gap: 10px; /* Space between icon and text if present */
  }

  /* Dropdown Menus (Inner Lists) */
  .navbar-nav .dropdown-menu {
      background: transparent;
      border: none;
      text-align: center;
      padding: 5px 0 15px 0;
  }

  .navbar-nav .dropdown-menu .dropdown-item {
       color: var(--text-muted) !important;
       padding: 8px 0;
       font-size: 0.95rem;
  }
  .navbar-nav .dropdown-menu .dropdown-item:hover {
       color: var(--accent) !important;
       background: transparent;
  }
}


/* FIX: Ensure code blocks in headers are transparent/dark to prevent White Box regression */
.glass-card h3 code, h3 code {
    background-color: transparent !important;
    color: inherit !important;
    padding: 0 !important;
}


/* NUCLEAR FIX: Remove background from ALL code blocks in glass cards to fix white box regression */
.glass-card code, .glass-card pre, h3 code, .level3 code {
    background: transparent !important;
    background-color: transparent !important;
    border: none !important;
    box-shadow: none !important;
    color: inherit !important;
    padding: 0 !important;
}

/* --- 9. DESKTOP TWO-ROW NAVBAR --- */
@media (min-width: 992px) {
  .navbar-container {
      display: flex;
      flex-direction: column;
      align-items: center;
  }
  .navbar-brand-container {
      margin: 0 auto 10px auto; /* Center brand and add bottom space */
  }
  .navbar-collapse {
      display: flex !important;
      justify-content: center;
      width: 100%;
  }
  .navbar-nav {
      justify-content: center;
      gap: 15px; /* Add spacing between items */
  }
}

/* --- 10. STICKY MOBILE CONTACT BUTTON --- */
.sticky-contact-btn {
    position: fixed;
    bottom: 25px;
    right: 25px;
    background: linear-gradient(135deg, var(--accent) 0%, #d46b1f 100%);
    color: #000 !important;
    padding: 12px 24px;
    border-radius: 50px;
    font-weight: 700;
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
    z-index: 1050; /* Above typical content */
    display: flex; /* Flex to align icon */
    align-items: center;
    gap: 8px;
    transition: transform 0.3s ease;
    text-decoration: none !important;
}
.sticky-contact-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 8px 30px rgba(242, 140, 61, 0.5);
    color: #000 !important;
}
