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

/* ===== Global Overflow Fix ===== */
body {
  overflow-x: clip;
  max-width: 100vw;
}

/* ===== Mobile Responsive Typography ===== */
@media (max-width: 767px) {
  h1 { font-size: 1.75rem !important; line-height: 1.2 !important; }
  h2 { font-size: 1.5rem !important; line-height: 1.25 !important; }
  h3 { font-size: 1.25rem !important; }
  .text-4xl, .text-5xl, .text-6xl, .text-7xl {
    font-size: 1.75rem !important;
    line-height: 1.2 !important;
  }
  .text-3xl { font-size: 1.5rem !important; }
  .text-2xl { font-size: 1.25rem !important; }
  .text-xl { font-size: 1.1rem !important; }
  section { padding-left: 1rem; padding-right: 1rem; }
}

/* =================================================================
   MOBILE RESPONSIVE OVERHAUL — Home Page
   ================================================================= */
@media (max-width: 767px) {

  /* ---- Global: Kill all horizontal overflow ---- */
  html, body {
    overflow-x: hidden !important;
    max-width: 100vw !important;
  }
  section, footer {
    width: 100% !important;
    max-width: 100vw !important;
    overflow-x: hidden !important;
    box-sizing: border-box !important;
  }
  /* Nav must NOT have overflow hidden — mobile menu is fixed child */
  nav {
    width: 100% !important;
    max-width: 100vw !important;
    box-sizing: border-box !important;
  }
  .max-w-7xl, .max-w-6xl, .max-w-5xl, .max-w-4xl, .max-w-3xl {
    max-width: 100% !important;
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }

  /* ---- Navigation ---- */
  nav .max-w-\[1440px\] {
    padding-left: 0.75rem !important;
    padding-right: 0.75rem !important;
  }

  /* ---- Hero Section ---- */
  #home {
    min-height: auto !important;
    padding-top: 6rem !important;
    padding-bottom: 3rem !important;
  }
  #home .pt-24 {
    padding-top: 1.5rem !important;
  }
  #home .mb-20 {
    margin-bottom: 2.5rem !important;
  }
  /* Hero buttons stack full-width */
  #home .flex.flex-col.sm\:flex-row {
    flex-direction: column !important;
    width: 100% !important;
  }
  #home .flex.flex-col.sm\:flex-row a {
    width: 100% !important;
    justify-content: center !important;
    padding: 1rem 1.5rem !important;
    font-size: 0.95rem !important;
  }
  /* Hero stats: 2-col tight grid */
  #home .grid.grid-cols-2 {
    grid-template-columns: 1fr 1fr !important;
    gap: 0.75rem !important;
  }
  #home .grid.grid-cols-2 > div {
    padding: 1rem !important;
    border-radius: 1rem !important;
  }
  #home .grid.grid-cols-2 .text-4xl,
  #home .grid.grid-cols-2 .text-5xl {
    font-size: 1.5rem !important;
  }
  #home .grid.grid-cols-2 .text-sm {
    font-size: 0.65rem !important;
  }
  /* Hide animated floating shapes on mobile */
  #home .float-animation {
    display: none !important;
  }

  /* ---- Professional Network / Marquee Section ---- */
  #partners {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
  #partners .mb-16 {
    margin-bottom: 1.5rem !important;
  }
  .logo-marquee-container {
    width: 100% !important;
    max-width: 100% !important;
  }
  .logo-marquee-track > div {
    min-width: 120px !important;
    padding: 0.5rem 0.75rem !important;
    height: 56px !important;
  }
  .logo-marquee-track > div span {
    font-size: 0.75rem !important;
  }

  /* ---- About Section Mobile ---- */
  #about .md\:hidden {
    padding: 3rem 1rem !important;
  }
  #about .md\:hidden .space-y-16 > * + * {
    margin-top: 1.25rem !important;
  }
  #about .md\:hidden .bg-\[\#111111\] {
    padding: 1.25rem !important;
    border-radius: 1rem !important;
  }

  /* ---- Features Section ---- */
  #features {
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
    min-height: auto !important;
  }
  #features .grid {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  #features .grid > div {
    padding: 1.25rem !important;
  }
  #features .grid .w-16 {
    width: 3rem !important;
    height: 3rem !important;
  }
  #features .grid .w-16 i {
    font-size: 1.1rem !important;
  }
  #features .mb-16 {
    margin-bottom: 1.5rem !important;
  }

  /* ---- Process Preview Section ---- */
  #features + section {
    min-height: auto !important;
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
  /* Process: stack grid to single column */
  .dark-section .grid.lg\:grid-cols-2 {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
  }
  /* Process floating badge — reposition */
  .dark-section .relative .absolute.-bottom-6.-left-6,
  .dark-section .relative .absolute {
    position: relative !important;
    bottom: auto !important;
    left: auto !important;
    margin-top: 1rem !important;
    display: inline-flex !important;
    width: auto !important;
  }

  /* ---- Testimonials / Review Marquee ---- */
  .marquee-container {
    max-width: 100% !important;
    width: 100% !important;
    padding: 0.75rem 0 !important;
  }
  .marquee-track > div {
    width: 280px !important;
    min-width: 280px !important;
    flex-shrink: 0 !important;
    padding: 1.25rem !important;
  }
  .marquee-track > div p {
    font-size: 0.85rem !important;
    margin-bottom: 1rem !important;
  }

  /* ---- Our Approach / Stats Section (3-col cards) ---- */
  .grid.md\:grid-cols-3 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  .grid.md\:grid-cols-3 > div {
    padding: 1.5rem !important;
  }
  .grid.md\:grid-cols-3 .w-16 {
    width: 3rem !important;
    height: 3rem !important;
  }
  .grid.md\:grid-cols-3 .mb-8 {
    margin-bottom: 1rem !important;
  }
  .grid.md\:grid-cols-3 h3 {
    font-size: 1.1rem !important;
  }

  /* ---- CTA Section ---- */
  .section-cta {
    min-height: auto !important;
    padding-top: 3rem !important;
    padding-bottom: 3rem !important;
  }
  .section-cta .flex.flex-col.sm\:flex-row {
    flex-direction: column !important;
    gap: 0.75rem !important;
  }
  .section-cta .flex.flex-col.sm\:flex-row a {
    width: 100% !important;
    justify-content: center !important;
    padding: 1rem 1.5rem !important;
    font-size: 0.95rem !important;
  }

  /* ---- Footer ---- */
  footer .grid {
    grid-template-columns: 1fr !important;
    gap: 2rem !important;
  }
  footer .max-w-7xl {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
  }
  footer .flex.flex-col.sm\:flex-row,
  footer .flex.flex-col.md\:flex-row {
    flex-direction: column !important;
    text-align: center !important;
    gap: 1rem !important;
  }
  footer .grid.md\:grid-cols-2 {
    grid-template-columns: 1fr !important;
  }
  footer .flex.items-center.gap-5 {
    justify-content: center !important;
  }
  footer .flex.items-center.gap-6 {
    flex-wrap: wrap !important;
    justify-content: center !important;
  }
  footer .flex.gap-4 {
    justify-content: center !important;
  }
  footer img {
    margin: 0 auto !important;
  }

  /* ---- Cookie Consent Banner ---- */
  #cookieConsent .flex.flex-col.md\:flex-row {
    flex-direction: column !important;
    text-align: center !important;
  }
  #cookieConsent .flex.items-center.gap-3 {
    width: 100% !important;
    justify-content: center !important;
  }
  #cookieConsent button {
    flex: 1 !important;
    min-width: 0 !important;
  }

  /* ---- Utility: tame all absolute blurs/shapes ---- */
  .blur-3xl {
    display: none !important;
  }
  .elegant-dots {
    display: none !important;
  }

  /* ---- General spacing tighten ---- */
  .py-24 { padding-top: 3rem !important; padding-bottom: 3rem !important; }
  .mb-16 { margin-bottom: 1.5rem !important; }
  .mb-20 { margin-bottom: 2rem !important; }
  .gap-16 { gap: 2rem !important; }
  .px-10 { padding-left: 1rem !important; padding-right: 1rem !important; }

  /* ---- Process steps spacing ---- */
  .space-y-6 > * + * {
    margin-top: 1rem !important;
  }
  .space-y-6 .w-12 {
    width: 2.5rem !important;
    height: 2.5rem !important;
    flex-shrink: 0 !important;
  }

  /* =================================================================
     CROSS-PAGE MOBILE RESPONSIVE — Pricing, Services, Contact,
     Checkout, Cart, Pay-Per-Lead
     ================================================================= */

  /* ---- All pages: min-height sections ---- */
  .min-h-screen {
    min-height: auto !important;
  }

  /* ---- All pages: hero sections (pt-32) ---- */
  .pt-32 {
    padding-top: 6rem !important;
  }

  /* ---- All pages: CTA buttons stacking ---- */
  .flex.flex-col.sm\:flex-row,
  .flex.sm\:flex-row {
    flex-direction: column !important;
  }
  .flex.flex-col.sm\:flex-row > a,
  .flex.flex-col.sm\:flex-row > button,
  .flex.sm\:flex-row > a,
  .flex.sm\:flex-row > button {
    width: 100% !important;
    justify-content: center !important;
    text-align: center !important;
  }

  /* ---- Dropdown menu mobile fix ---- */
  .dropdown-menu {
    min-width: 200px !important;
  }

  /* ---- PRICING PAGE ---- */

  /* Pricing cards grid */
  .grid.md\:grid-cols-3.gap-8 {
    grid-template-columns: 1fr !important;
    gap: 1.25rem !important;
  }
  /* Remove scale on featured pricing card */
  .pricing-card.featured {
    transform: none !important;
  }
  .pricing-card.featured:hover {
    transform: none !important;
  }
  .pricing-card {
    padding: 1.5rem !important;
  }
  /* Pricing/PPL large price text */
  .pricing-card .text-6xl,
  .ppl-card .text-6xl {
    font-size: 2.5rem !important;
  }
  /* Pricing/PPL plan icons */
  .pricing-card .w-20.h-20,
  .ppl-card .w-20.h-20 {
    width: 3.5rem !important;
    height: 3.5rem !important;
  }
  .pricing-card .w-20.h-20 i,
  .ppl-card .w-20.h-20 i {
    font-size: 1.25rem !important;
  }

  /* Team/Brokerage cards */
  .grid.md\:grid-cols-2.gap-8 {
    grid-template-columns: 1fr !important;
    gap: 1.25rem !important;
  }

  /* Comparison table — make it scrollable + compact */
  .features-table {
    font-size: 0.7rem !important;
    min-width: 500px !important;
  }
  .features-table th,
  .features-table td {
    padding: 0.5rem 0.35rem !important;
    font-size: 0.7rem !important;
    white-space: nowrap !important;
  }
  .features-table td:first-child,
  .features-table th:first-child {
    white-space: normal !important;
    min-width: 100px !important;
    max-width: 120px !important;
  }
  /* Ensure the table container scrolls */
  .overflow-x-auto {
    overflow-x: auto !important;
    -webkit-overflow-scrolling: touch !important;
    padding: 0 !important;
  }

  /* Custom Plan CTA strip */
  .bg-gradient-to-r.from-\[\#4D2327\] {
    padding: 1.5rem !important;
  }
  .bg-gradient-to-r.from-\[\#4D2327\] .flex.flex-col.md\:flex-row {
    flex-direction: column !important;
    text-align: center !important;
    gap: 1rem !important;
  }

  /* Guarantee section */
  .rounded-3xl.p-12 {
    padding: 1.5rem !important;
  }
  .flex.flex-wrap.justify-center.gap-8 {
    gap: 1.5rem !important;
  }

  /* ---- SERVICES PAGE ---- */

  /* Service cards */
  .grid.md\:grid-cols-2.gap-8,
  .grid.md\:grid-cols-2.gap-10 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  .card-hover {
    padding: 1.25rem !important;
  }
  /* Additional services grid (4-col) */
  .grid.md\:grid-cols-2.lg\:grid-cols-4 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  /* ---- CONTACT PAGE ---- */

  /* Contact form tabs */
  .flex.flex-wrap.justify-center.gap-4 {
    gap: 0.5rem !important;
  }
  .form-tab {
    padding: 0.5rem 1rem !important;
    font-size: 0.8rem !important;
  }

  /* Form grids */
  .grid.md\:grid-cols-2.gap-6,
  .grid.md\:grid-cols-3.gap-6 {
    grid-template-columns: 1fr !important;
    gap: 0.75rem !important;
  }

  /* Form container padding */
  .form-panel .rounded-2xl,
  .form-panel .rounded-3xl {
    padding: 1.25rem !important;
  }
  .form-input {
    padding: 0.75rem !important;
    font-size: 0.9rem !important;
  }

  /* ---- CHECKOUT PAGE ---- */

  /* Checkout grid layout */
  .grid.lg\:grid-cols-5 {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }
  /* Reorder: summary on top, form below */
  .grid.lg\:grid-cols-5 > .order-2 {
    order: 1 !important;
  }
  .grid.lg\:grid-cols-5 > .order-1 {
    order: 2 !important;
  }
  /* Summary card sticky on mobile = no sticky */
  .sticky.top-28 {
    position: relative !important;
    top: auto !important;
  }
  /* Form card inner padding */
  .grid.lg\:grid-cols-5 .p-8,
  .grid.lg\:grid-cols-5 .md\:p-12 {
    padding: 1.25rem !important;
  }
  /* Progress steps compact */
  .flex.items-center.justify-center.gap-2 {
    gap: 0.25rem !important;
    flex-wrap: wrap !important;
  }
  .flex.items-center.justify-center.gap-2 .text-sm {
    font-size: 0.7rem !important;
  }
  /* Stripe input */
  .stripe-input {
    padding: 0.75rem !important;
  }

  /* ---- CART PAGE ---- */

  /* Plan tabs */
  .flex.justify-center .plan-tab {
    padding: 0.5rem 1rem !important;
    font-size: 0.85rem !important;
  }
  /* Plan cards grids */
  .grid.md\:grid-cols-3.gap-6 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  .grid.md\:grid-cols-2.gap-6 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  /* Plan card padding */
  .plan-card,
  .pricing-card {
    padding: 1.25rem !important;
  }

  /* ---- PAY-PER-LEAD PAGE ---- */

  /* PPL cards grid */
  .grid.md\:grid-cols-2.gap-10 {
    grid-template-columns: 1fr !important;
    gap: 1.25rem !important;
  }
  /* PPL card featured remove scale */
  .ppl-card.featured {
    transform: none !important;
  }
  .ppl-card.featured:hover {
    transform: none !important;
  }
  .ppl-card {
    padding: 1.5rem !important;
  }

  /* Plan badges — smaller on mobile (pricing + PPL pages) */
  .pricing-card .absolute.-top-4 span,
  .ppl-card .absolute.-top-4 span {
    padding: 0.3rem 0.75rem !important;
    font-size: 0.65rem !important;
    white-space: nowrap !important;
  }
  .pricing-card .absolute.-top-4,
  .ppl-card .absolute.-top-4 {
    top: -0.6rem !important;
  }

  /* How it works */
  .grid.md\:grid-cols-3.gap-8 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  /* ---- PROCESS PAGE ---- */

  /* Comparison table: KEEP side-by-side but compact for mobile */
  .max-w-5xl .grid.grid-cols-2 {
    grid-template-columns: 1fr 1fr !important;
  }
  /* Comparison: tight padding */
  .max-w-5xl .grid.grid-cols-2 > div {
    padding: 0.65rem 0.5rem !important;
  }
  /* Comparison: smaller text */
  .max-w-5xl .grid.grid-cols-2 .font-semibold {
    font-size: 0.7rem !important;
    line-height: 1.3 !important;
  }
  .max-w-5xl .grid.grid-cols-2 .text-sm {
    font-size: 0.6rem !important;
    line-height: 1.3 !important;
  }
  /* Comparison header icons smaller */
  .max-w-5xl .grid.grid-cols-2 .w-12 {
    width: 2rem !important;
    height: 2rem !important;
  }
  .max-w-5xl .grid.grid-cols-2 .w-12 i {
    font-size: 0.7rem !important;
  }
  /* Comparison check/x icons smaller */
  .max-w-5xl .grid.grid-cols-2 .w-8 {
    width: 1.25rem !important;
    height: 1.25rem !important;
    min-width: 1.25rem !important;
  }
  .max-w-5xl .grid.grid-cols-2 .w-8 i {
    font-size: 0.55rem !important;
  }
  /* Comparison header title */
  .max-w-5xl .grid.grid-cols-2 h3 {
    font-size: 0.8rem !important;
  }
  .max-w-5xl .grid.grid-cols-2 .text-lg {
    font-size: 0.75rem !important;
  }
  /* Gap between icon and text */
  .max-w-5xl .grid.grid-cols-2 .gap-4 {
    gap: 0.35rem !important;
  }
  /* Comparison container shadow */
  .max-w-5xl.shadow-2xl {
    border-radius: 0.75rem !important;
    overflow: hidden !important;
  }

  /* Lead sources grid (lg:grid-cols-2) */
  .grid.lg\:grid-cols-2.gap-12 {
    grid-template-columns: 1fr !important;
    gap: 1.5rem !important;
  }
  /* Lead sources cards */
  .grid.lg\:grid-cols-2 .rounded-3xl {
    padding: 1.25rem !important;
  }

  /* State progress bars — make responsive */
  .state-item .w-32 {
    width: 4rem !important;
  }
  .state-item {
    padding: 0.5rem 0.75rem !important;
  }

  /* Lead source cards compact on mobile */
  .lead-card {
    padding: 0.75rem !important;
  }
  .lead-card .w-12 {
    width: 2.5rem !important;
    height: 2.5rem !important;
  }
  .lead-card .text-2xl {
    font-size: 1.25rem !important;
  }

  /* Timeline step spacing */
  .timeline-step {
    margin-bottom: 3rem !important;
  }
  .timeline-step .grid.md\:grid-cols-2 {
    grid-template-columns: 1fr !important;
  }
  /* Timeline cards compact */
  .timeline-content {
    padding: 1.25rem !important;
  }
  /* Timeline icon on mobile */
  .timeline-icon {
    width: 50px !important;
    height: 50px !important;
  }
  .timeline-icon i {
    font-size: 1.1rem !important;
  }

  /* Advantages grid (md:grid-cols-2 lg:grid-cols-3) */
  .grid.md\:grid-cols-2.lg\:grid-cols-3 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }
  .grid.md\:grid-cols-2.lg\:grid-cols-3 > div {
    padding: 1.25rem !important;
  }
  .grid.md\:grid-cols-2.lg\:grid-cols-3 .w-16 {
    width: 3rem !important;
    height: 3rem !important;
  }

  /* ---- All pages: general fixes ---- */

  /* Absolute badges — avoid overflow */
  .absolute.-top-4,
  .absolute.-top-3 {
    position: absolute !important;
    left: 50% !important;
    transform: translateX(-50%) !important;
  }

  /* All grids: 4-col to single */
  .grid.lg\:grid-cols-4 {
    grid-template-columns: 1fr !important;
    gap: 1rem !important;
  }

  /* Large inner padding reductions */
  .p-12 { padding: 1.25rem !important; }
  .p-10 { padding: 1rem !important; }
  .p-8 { padding: 1rem !important; }
  .md\:p-12 { padding: 1.25rem !important; }
  .md\:p-8 { padding: 1rem !important; }

  /* CTA section stacking (all pages) */
  .bg-primary .flex.flex-col.sm\:flex-row a,
  .section-cta .flex.flex-col.sm\:flex-row a {
    width: 100% !important;
    text-align: center !important;
    justify-content: center !important;
  }

  /* Large glow effects hidden globally */
  .w-\[600px\], .w-96.h-96, .w-72.h-72 {
    display: none !important;
  }
}

/* ===== Mobile Nav Dropdown Toggle ===== */
.mobile-dropdown-items {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1), opacity 0.25s ease;
  opacity: 0;
}
.mobile-dropdown-items.open {
  max-height: 300px;
  opacity: 1;
}
.mobile-dropdown-toggle .chevron-icon {
  transition: transform 0.3s ease;
}
.mobile-dropdown-toggle.open .chevron-icon {
  transform: rotate(180deg);
}

/* ===== Mobile Menu Slide Animation ===== */
.mobile-menu {
  transform: translateX(-100%);
  transition: transform 0.4s cubic-bezier(0.22, 1, 0.36, 1);
}
.mobile-menu.active {
  transform: translateX(0);
}

/* ===== Mobile Nav Logo ===== */
@media (max-width: 1023px) {
  nav [class*="max-w-"][class*="mx-auto"] {
    padding-left: max(env(safe-area-inset-left), 0rem) !important;
    padding-right: max(env(safe-area-inset-right), 0rem) !important;
  }
  nav .flex.justify-between {
    width: 100%;
    justify-content: space-between;
    align-items: center;
    gap: 0;
  }
  nav .flex.justify-between > a:first-child {
    display: flex;
    align-items: center;
    margin-right: auto;
    margin-left: 0 !important;
    padding-left: 0 !important;
  }
  nav .flex.justify-between > a:first-child img {
    display: block;
    transform: translateX(-5px);
  }
  nav .flex.justify-between > button {
    margin-left: auto;
    margin-right: -2px !important;
    width: 2.5rem;
    height: 2.5rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    line-height: 1;
    flex: 0 0 auto;
  }
  nav .flex.justify-between > button i {
    line-height: 1;
  }
}

:root {
  /* Fonts */
  --font-primary: "ivypresto-display", "Georgia", serif;
  --font-secondary: "Inter", "Helvetica Neue", Arial, sans-serif;

  /* Colors */
  --color-bg-primary: #0A0A0A;
  --color-bg-secondary: #FFFFFF;
  --color-text-primary: #FFFFFF;
  --color-text-secondary: #B0B0B0;
  --color-text-muted: #777777;
  --color-border: #222222;

  /* Brand colors as RGB triplets for rgba() usage */
  --color-brand-primary: 10, 10, 10;
  --color-brand-accent: 77, 35, 39;
  --color-brand-secondary: 54, 22, 29;

  /* Direct hex values */
  --color-accent: #4D2327;
  --color-accent-light: #6B3338;
  --color-accent-dark: #36161D;
}

body {
  font-family: var(--font-secondary);
  background-color: var(--color-bg-primary);
  color: var(--color-text-secondary);
  font-weight: 400;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-primary);
  font-weight: 500;
  line-height: 1.2;
  color: var(--color-text-primary);
}

.font-montserrat, nav {
  font-family: var(--font-secondary);
}

/* Make logo white on dark backgrounds */
img[src*="RISE ESTATE LOGO"],
img[src*="RISE%20ESTATE%20LOGO"] {
  filter: brightness(0) invert(1);
}

/* Active nav link indicator */
nav a.nav-active:not(.btn-accent):not(:has(img)) {
  color: #FFFFFF !important;
  border-bottom: 2px solid #4D2327;
  padding-bottom: 4px;
}

/* Active link inside dropdown menus (white bg — use maroon, not white) */
.dropdown-menu a.dropdown-active {
  background: rgba(77, 35, 39, 0.1) !important;
  color: #4D2327 !important;
  font-weight: 600;
}

/* ===== Scrollbar ===== */
::-webkit-scrollbar { width: 8px; }
::-webkit-scrollbar-track { background: #0A0A0A; }
::-webkit-scrollbar-thumb { background: #4D2327; border-radius: 4px; }
::-webkit-scrollbar-thumb:hover { background: #6B3338; }

/* ===== Back to Top ===== */
#back-to-top {
  position: fixed;
  bottom: 28px;
  right: 28px;
  width: 36px;
  height: 36px;
  background: linear-gradient(168deg, #4D2327 0%, #36161D 100%);
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #FFFFFF;
  font-size: 13px;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: opacity 0.3s ease, visibility 0.3s ease, transform 0.3s ease, filter 0.2s ease;
  z-index: 9998;
  border: 1px solid rgba(155, 90, 96, 0.3);
  box-shadow: 0 4px 16px rgba(77, 35, 39, 0.4);
}
#back-to-top.btt-visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}
#back-to-top:hover {
  filter: brightness(1.25);
  transform: translateY(-3px);
  box-shadow: 0 6px 22px rgba(77, 35, 39, 0.6);
}

/* ===== Page Loader ===== */
#page-loader {
  position: fixed;
  inset: 0;
  background: #0A0A0A;
  z-index: 99999;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}
#page-loader .loader-top-bar {
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(90deg, #36161D, #4D2327 40%, #C4787E 70%, #4D2327);
}
#page-loader.loader-fade-out {
  animation: loaderFadeOut 0.6s ease forwards;
  pointer-events: none;
}
@keyframes loaderFadeOut {
  to { opacity: 0; }
}
.loader-logo {
  height: 180px;
  width: auto;
  filter: brightness(0) invert(1) !important;
  opacity: 0;
  animation: loaderIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.1s forwards;
}
.loader-tagline {
  color: rgba(255, 255, 255, 0.3);
  font-family: 'Inter', 'Helvetica Neue', sans-serif;
  font-size: 9.5px;
  letter-spacing: 5px;
  text-transform: uppercase;
  margin-top: 16px;
  opacity: 0;
  animation: loaderIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.25s forwards;
}
.loader-bar-track {
  width: 150px;
  height: 1px;
  background: rgba(255, 255, 255, 0.08);
  margin-top: 30px;
  overflow: hidden;
  opacity: 0;
  animation: loaderIn 0.8s cubic-bezier(0.22, 1, 0.36, 1) 0.35s forwards;
}
.loader-bar {
  height: 100%;
  width: 0;
  background: linear-gradient(90deg, #4D2327, #C4787E);
  animation: loaderBarFill 1.1s ease 0.45s forwards;
}
@keyframes loaderIn {
  from { opacity: 0; transform: translateY(-10px); }
  to   { opacity: 1; transform: translateY(0); }
}
@keyframes loaderBarFill {
  0%   { width: 0%; }
  45%  { width: 60%; }
  100% { width: 100%; }
}
.loader-skyline {
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 180px;
  color: rgba(255, 255, 255, 0.045);
  clip-path: inset(100% 0 0 0);
  animation: buildingsRise 1.6s cubic-bezier(0.22, 1, 0.36, 1) 0.15s forwards;
}
@keyframes buildingsRise {
  from { clip-path: inset(100% 0 0 0); }
  to   { clip-path: inset(0% 0 0 0); }
}
