/* ==============================================================================
   STYLE.CSS — COMBINED STYLESHEET
   ==============================================================================

   TABLE OF CONTENTS
   ------------------------------------------------------------------------------
   01. ROOT VARIABLES ............. CSS custom properties & design tokens
   02. RESET CSS .................. Box-model reset & base element defaults
   03. GLOBAL CSS ................. Body, container, shared utility classes
   04. LAYOUT CSS ................. Main grid, content area, quick-links
   05. HEADER CSS ................. Site header, nav, mega menu, search overlay
   06. HERO CSS ................... Hero section, orbs, chips, stat pills
   07. SIDEBAR CSS ................ Sidebar wrapper, sticky behaviour, ad slots
   08. ALL TOOLS CSS .............. Tools section, category nav, tool cards
   09. POPULAR & RELATED TOOLS CSS  Inline tools wrapper, animated border cards
   10. AFFILIATE CSS .............. Affiliate cards & brand themes
   11. ADS CSS .................... Ad box placeholder
   12. FOOTER CSS ................. Site footer grid & responsive rules
   13. RESPONSIVE CSS ............. Global media-query overrides
   14. COOKIE CONSENT CSS ......... Bottom cookie bar, accept/reject actions
   ==============================================================================
*/

/* ==============================================================================
   ROOT VARIABLES START
   ============================================================================== */

:root {
  --primary-color: #2563eb;
  --secondary-color: #1e293b;
  --background-color: #f8fafc;
  --surface-color: #ffffff;
  --text-color: #0f172a;
  --border-color: #e2e8f0;

  --container-width: 1400px;
  --sidebar-width: 320px;

  --radius: 14px;

  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 5px 20px rgba(0, 0, 0, 0.08);

  --transition: 0.3s ease;
  --navy: #0f1b35;
  --main-dark: #33373d;
  --main-color: #0ea87a;
  --main-body: #f0f4ff;
  --main-pra: #6b7280;
  --main-card-bg: #f8faff;
  --main-ibg: #f0fdf4;
}

/* ==============================================================================
   ROOT VARIABLES END
   ============================================================================== */

/* ==============================================================================
   RESET CSS START
   ============================================================================== */

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  min-height: 100vh;
}

img {
  max-width: 100%;
}

a {
  text-decoration: none;
}

button,
input,
textarea,
select {
  font: inherit;
}

/* ==============================================================================
   RESET CSS END
   ============================================================================== */

/* ==============================================================================
   GLOBAL CSS START
   ============================================================================== */

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  background: var(--main-body);
  color: var(--main-dark);
  line-height: 1.6;
  padding-top: 55px;
}

.container {
  width: 100%;
  max-width: var(--container-width);
  margin-inline: auto;
  padding-inline: 20px;
}

/* ==============================================================================
   GLOBAL CSS END
   ============================================================================== */

/* ==============================================================================
   LAYOUT CSS START
   ============================================================================== */

.main-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--sidebar-width);
  gap: 24px;
  margin-top: 0px;
  margin-bottom: 50px;
}

.content-area {
  min-width: 0;
}

.sidebar-area {
  position: relative;
  min-width: 0;
  width: 100%;
}

.tool-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 20px;
}

.tool-card {
  background: var(--surface-color);
  border-radius: var(--radius);
  padding: 24px;
  box-shadow: var(--shadow-sm);
  transition: var(--transition);
  height: 100%;
}

/* ---------- The link list component every page  ---------- */
.quick-links {
  width: 98% !important;
  padding: 20px !important;
  margin-top: 10px !important;
  margin-left: auto !important;
  margin-right: auto !important;
  margin-bottom: 20px !important;
  border: solid 1px var(--border-color) !important;
  border-radius: var(--radius) !important;
}

.quick-links h2 {
  font-size: 1.4rem !important;
  font-weight: 700 !important;
  margin-bottom: 20px !important;
}
.quick-links .link-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.quick-links .link-item__anchor {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 7px 14px;
  border-radius: 12px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-left: 4px solid var(--accent);
  text-decoration: none;
  color: #1f2937;
  font-size: 0.8rem !important;
  font-weight: 700;
  letter-spacing: 0.01em;
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
  transition:
    background-color 0.25s ease,
    border-color 0.25s ease,
    color 0.25s ease,
    transform 0.25s ease,
    box-shadow 0.25s ease;
}

.link-item__arrow {
  flex-shrink: 0;
  font-weight: 800;
  font-size: 0.7rem;
  line-height: 1;
  color: var(--accent);
  transition:
    transform 0.25s ease,
    color 0.25s ease;
}

.link-item__anchor:hover,
.link-item__anchor:focus-visible {
  background: var(--accent);
  border-color: var(--accent);
  color: #ffffff;
  transform: translateX(6px);
  box-shadow: 0 10px 24px -8px var(--accent);
  text-decoration: none !important;
}

.link-item__anchor:hover .link-item__arrow,
.link-item__anchor:focus-visible .link-item__arrow {
  color: #ffffff;
  transform: translateX(4px);
}

.link-item__anchor:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.link-item__anchor:active {
  transform: translateX(6px) scale(0.99);
}

/* ---------- Five distinct accent colors ---------- */

.link-item:nth-child(1) .link-item__anchor {
  --accent: #2563eb;
} /* blue    */
.link-item:nth-child(2) .link-item__anchor {
  --accent: #059669;
} /* emerald */
.link-item:nth-child(3) .link-item__anchor {
  --accent: #d97706;
} /* amber   */
.link-item:nth-child(4) .link-item__anchor {
  --accent: #e11d48;
} /* rose    */
.link-item:nth-child(5) .link-item__anchor {
  --accent: #7c3aed;
} /* violet  */

/* ==============================================================================
   LAYOUT CSS END
   ============================================================================== */

/* ==============================================================================
   HEADER CSS START
   ============================================================================== */

/* =========================================================
   HEADER
========================================================= */

.site-header {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 1000;
  width: 100%;
  background: #0f1b35;
  border-bottom: 1px solid rgba(255, 255, 255, 0.07);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
}

.site-header::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: linear-gradient(90deg, #0ea87a 0%, #06b6d4 50%, #0ea87a 100%);
  background-size: 200% 100%;
  animation: header-line 4s linear infinite;
}

@keyframes header-line {
  0% {
    background-position: 0% 0%;
  }
  100% {
    background-position: 200% 0%;
  }
}

.site-header::after {
  content: "";
  position: absolute;
  top: -40px;
  right: -60px;
  width: 220px;
  height: 100px;
  border-radius: 50%;
  background: radial-gradient(
    circle,
    rgba(14, 168, 122, 0.18) 0%,
    transparent 70%
  );
  pointer-events: none;
}

/* =========================================================
   HEADER WRAPPER
========================================================= */

.header-wrapper {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 56px;
  position: relative;
  z-index: 1;
  gap: 10px;
}

/* =========================================================
   LOGO
========================================================= */
.site-header .calculator-logo {
  display: block;
  width: auto;
  height: 37px;
}

/* =========================================================
   DESKTOP NAV
========================================================= */

.nav-menu {
  display: flex;
  align-items: center;
  gap: 2px;
}

.nav-menu > a,
.mega-menu-button {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.58);
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  padding: 6px 12px;
  border-radius: 8px;
  text-decoration: none;
  transition:
    color 0.25s ease,
    background 0.25s ease;
  font-family: inherit;
  white-space: nowrap;
}

.nav-menu > a:hover,
.mega-menu-button:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.08);
}

.nav-menu > a.menuActive {
  color: #fff;
  background: rgba(255, 255, 255, 0.09);
}

.nav-menu > a.menuActive::after {
  content: "";
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 4px;
  border-radius: 50%;
  background: #0ea87a;
}

.chev-icon {
  font-size: 10px;
  transition: transform 0.3s ease;
}

.mega-menu-wrapper:hover .chev-icon {
  transform: rotate(180deg);
}

/* =========================================================
   NAV CTA BUTTON
========================================================= */

.nav-cta {
  display: inline-flex !important;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #0ea87a 0%, #059669 100%) !important;
  color: #fff !important;
  font-weight: 700 !important;
  padding: 6px 14px !important;
  border-radius: 8px !important;
  margin-left: 6px;
  text-decoration: none;
  box-shadow: 0 4px 12px rgba(14, 168, 122, 0.38);
  transition:
    transform 0.25s ease,
    box-shadow 0.25s ease !important;
}

.nav-cta:hover {
  box-shadow: 0 6px 18px rgba(14, 168, 122, 0.5) !important;
}

/* =========================================================
   MEGA MENU WRAPPER
========================================================= */

.mega-menu-wrapper {
  height: 55px;
  align-content: center;
  position: relative;
}

/* =========================================================
   MEGA MENU DROPDOWN
========================================================= */

.mega-menu {
  position: fixed;
  top: 55px;
  left: 50%;
  transform: translateX(-50%) translateY(-8px);
  width: min(1380px, calc(100vw - 32px));
  max-height: calc(100vh - 90px);
  overflow-y: auto;
  background: #ffffff;
  border-radius: 20px;
  padding: 0;
  box-shadow:
    0 24px 60px rgba(0, 0, 0, 0.12),
    0 4px 16px rgba(0, 0, 0, 0.06);
  border: 1px solid #e0eaff;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.25s ease,
    transform 0.25s ease,
    visibility 0.25s ease;
}

.mega-menu-wrapper:hover .mega-menu {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transform: translateX(-50%) translateY(0);
}

/* =========================================================
   MEGA MENU TOP BAR
========================================================= */

.mega-menu-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 24px;
  border-bottom: 1px solid #f0f4ff;
  background: linear-gradient(135deg, #f8faff 0%, #f0fdf8 100%);
  border-radius: 20px 20px 0 0;
}

.mega-menu-label {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  font-size: 12.5px;
  font-weight: 700;
  color: #0f172a;
}

.mega-menu-label i {
  color: #0ea87a;
  font-size: 13px;
}

.mega-menu-count {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11.5px;
  font-weight: 700;
  color: #065f46;
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  border: 1px solid #6ee7b7;
  border-radius: 20px;
  padding: 3px 11px;
}

/* =========================================================
   MEGA GRID
========================================================= */

.mega-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
  padding: 20px;
}

/* =========================================================
   MEGA SECTION
========================================================= */

.mega-section {
  background: #f8faff;
  border: 1px solid #e8f0fe;
  border-radius: 14px;
  padding: 16px;
  transition:
    border-color 0.25s ease,
    transform 0.25s ease,
    box-shadow 0.25s ease;
  position: relative;
  overflow: hidden;
}

.mega-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: linear-gradient(180deg, #0ea87a, #06b6d4);
  border-radius: 3px 0 0 3px;
  opacity: 1;
  transition: width 0.25s ease;
}

.mega-section:hover {
  border-color: #a7f3d0;
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(14, 168, 122, 0.09);
}

.mega-section:hover::before {
  width: 4px;
}

.mega-section h3 {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 700;
  color: #0ea87a;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding-bottom: 8px;
  border-bottom: 1px solid #e8f0fe;
}

.mega-section h3 i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  font-size: 10px;
  color: #fff;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.18);
  transition: transform 0.25s ease;
}

.mega-section:hover h3 i {
  transform: scale(1.08);
}

.mega-section ul {
  list-style: none;
}

.mega-section li + li {
  margin-top: 3px;
}

.mega-section a {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  color: #475569;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  transition:
    color 0.2s ease,
    transform 0.2s ease;
  line-height: 1.5;
}

.mega-section a::before {
  content: "›";
  color: #cbd5e1;
  font-size: 14px;
  transition: color 0.2s ease;
  flex-shrink: 0;
}

.mega-section a:hover {
  color: #0ea87a;
  transform: translateX(3px);
}

.mega-section a:hover::before {
  color: #0ea87a;
}

.mega-menu::-webkit-scrollbar {
  width: 6px;
}
.mega-menu::-webkit-scrollbar-track {
  background: transparent;
}
.mega-menu::-webkit-scrollbar-thumb {
  background: #d1fae5;
  border-radius: 20px;
}

/* =========================================================
   DESKTOP SEARCH BUTTON
========================================================= */

.header-search-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 10px;
  padding: 6px 12px;
  color: rgba(255, 255, 255, 0.5);
  font-size: 12.5px;
  font-weight: 500;
  font-family: inherit;
  cursor: pointer;
  margin-left: 6px;
  transition: all 0.25s ease;
  white-space: nowrap;
  flex-shrink: 0;
}

.header-search-btn:hover {
  background: rgba(255, 255, 255, 0.11);
  border-color: rgba(14, 168, 122, 0.4);
  color: rgba(255, 255, 255, 0.8);
}

.header-search-btn i {
  font-size: 11.5px;
  color: #0ea87a;
}

.search-kbd {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 5px;
  padding: 1px 6px;
  font-size: 10.5px;
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 0.02em;
  margin-left: 4px;
}

/* =========================================================
   MOBILE CONTROLS GROUP
   (wraps search icon + hamburger together on the right)
========================================================= */

.mobile-controls {
  display: none;
  align-items: center;
  gap: 7px;
  flex-shrink: 0;
}

/* =========================================================
   MOBILE SEARCH ICON BUTTON (inside mobile-controls)
========================================================= */

/* =========================================================
   MOBILE HAMBURGER (inside mobile-controls)
========================================================= */

.mobile-menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 5px;
  width: 34px;
  height: 34px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.12);
  border-radius: 9px;
  cursor: pointer;
  padding: 0 7px;
  flex-shrink: 0;
  position: relative;
  z-index: 3000;
}

.mobile-menu-toggle span {
  display: block;
  width: 100%;
  height: 1.8px;
  background: #ffffff;
  border-radius: 20px;
  transition: 0.3s ease;
  pointer-events: none;
}

/* =========================================================
   MOBILE SEARCH BAR
   (tappable fake input in the center of header on mobile)
========================================================= */

.mobile-search-bar {
  display: none;
  align-items: center;
  gap: 8px;
  background: rgba(255, 255, 255, 0.07);
  border: 1px solid rgba(255, 255, 255, 0.11);
  border-radius: 10px;
  padding: 7px 12px;
  cursor: pointer;
  flex: 1;
  min-width: 0;
  transition:
    border-color 0.2s ease,
    background 0.2s ease;
}

.mobile-search-bar:hover {
  border-color: rgba(14, 168, 122, 0.4);
  background: rgba(255, 255, 255, 0.1);
}

.mobile-search-bar i {
  color: #0ea87a;
  font-size: 12px;
  flex-shrink: 0;
}

.mobile-search-bar span {
  font-size: 12px;
  font-weight: 400;
  color: rgba(255, 255, 255, 0.38);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  line-height: 1;
}

/* =========================================================
   MOBILE MENU PANEL
========================================================= */

.mobile-menu {
  position: fixed;
  top: 0;
  right: -320px;
  width: 320px;
  max-width: 100%;
  height: 100%;
  background: #ffffff;
  z-index: 2500;
  padding: 80px 20px 30px;
  overflow-y: auto;
  transition: right 0.38s cubic-bezier(0.4, 0, 0.2, 1);
}

.mobile-menu.active {
  right: 0;
}

/* =========================================================
   MOBILE MENU OVERLAY
========================================================= */

.mobile-menu-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 27, 53, 0.55);
  backdrop-filter: blur(3px);
  opacity: 0;
  visibility: hidden;
  z-index: 2000;
  transition: 0.3s ease;
}

.mobile-menu-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* =========================================================
   MOBILE MENU HEADER
========================================================= */

.mobile-menu-header {
  position: absolute;
  top: 0;
  left: 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  height: 62px;
  padding: 0 18px;
  background: #ffffff;
  border-bottom: 1px solid #f0f4ff;
}

/* =========================================================
   MOBILE CLOSE BUTTON
========================================================= */

.mobile-menu-close {
  position: relative;
  width: 32px;
  height: 32px;
  background: #f0fdf8;
  border: 1px solid #d1fae5;
  border-radius: 9px;
  cursor: pointer;
  flex-shrink: 0;
}

.mobile-menu-close span {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 16px;
  height: 1.8px;
  background: #0ea87a;
  border-radius: 20px;
}

.mobile-menu-close span:first-child {
  transform: translate(-50%, -50%) rotate(45deg);
}

.mobile-menu-close span:last-child {
  transform: translate(-50%, -50%) rotate(-45deg);
}

/* =========================================================
   MOBILE TOP LINKS
========================================================= */

.mobile-menu-top {
  display: flex;
  flex-direction: column;
  gap: 2px;
  padding-bottom: 20px;
  border-bottom: 1px solid #f0f4ff;
}

.mobile-menu-top a {
  display: flex;
  align-items: center;
  gap: 10px;
  color: #0f172a;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 12px;
  border-radius: 10px;
  text-decoration: none;
  transition:
    background 0.2s ease,
    color 0.2s ease;
}

.mobile-menu-top a i {
  width: 18px;
  color: #0ea87a;
  font-size: 13px;
}

.mobile-menu-top a:hover {
  background: #f0fdf8;
  color: #0ea87a;
}

/* =========================================================
   MOBILE BOTTOM
========================================================= */

.mobile-menu-bottom {
  padding-top: 20px;
}

.mobile-menu-bottom h3 {
  font-size: 11px;
  font-weight: 700;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: 14px;
  padding-left: 2px;
}

/* =========================================================
   MOBILE TOOL SECTIONS
========================================================= */

.mobile-tools-sections {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.mobile-tool-section {
  background: #f8faff;
  border: 1px solid #e8f0fe;
  border-radius: 13px;
  padding: 14px;
  position: relative;
  overflow: hidden;
  transition: border-color 0.2s ease;
}

.mobile-tool-section::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 3px;
  height: 100%;
  background: linear-gradient(180deg, #0ea87a, #06b6d4);
}

.mobile-tool-section:hover {
  border-color: #a7f3d0;
}

.mobile-tool-section h4 {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
  font-size: 12px;
  font-weight: 700;
  color: #0ea87a;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  padding-bottom: 8px;
  border-bottom: 1px solid #e8f0fe;
}

.mobile-tool-section h4 i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  font-size: 10px;
  color: #fff;
  box-shadow: 0 2px 6px rgba(15, 23, 42, 0.18);
}

.mobile-tool-section ul {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 10px;
  list-style: none;
}

.mobile-tool-section a {
  display: flex;
  align-items: center;
  gap: 5px;
  color: #475569;
  font-size: 12px;
  font-weight: 500;
  text-decoration: none;
  line-height: 1.4;
  transition: color 0.2s ease;
}

.mobile-tool-section a::before {
  content: "›";
  color: #cbd5e1;
  font-size: 14px;
  transition: color 0.2s ease;
  flex-shrink: 0;
}

.mobile-tool-section a:hover {
  color: #0ea87a;
}

.mobile-tool-section a:hover::before {
  color: #0ea87a;
}

/* =========================================================
   CATEGORY COLOR SYSTEM
   Every category gets its own background tint, heading color,
   accent bar, and icon shape — shared between the desktop
   mega-menu and the mobile menu so categories are instantly
   recognizable the moment either menu opens.
========================================================= */

/* ---- 1. Women Health Tools — rose / circle ---- */
.mega-grid > .mega-section:nth-child(1),
.mobile-tools-sections > .mobile-tool-section:nth-child(1) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#fdf2f8, #fdf2f8), linear-gradient(135deg, #fbcfe8, #f9a8d4);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(1) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(1) h4 {
  color: #be185d;
  border-bottom-color: #fbcfe8;
}
.mega-grid > .mega-section:nth-child(1)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(1)::before {
  background: linear-gradient(180deg, #f472b6, #db2777);
}
.mega-grid > .mega-section:nth-child(1) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(1) h4 i {
  background: linear-gradient(135deg, #f472b6, #db2777);
  border-radius: 50%;
}
.mega-grid > .mega-section:nth-child(1):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(1):hover {
  box-shadow: 0 6px 20px rgba(219, 39, 119, 0.16);
}
.mega-grid > .mega-section:nth-child(1) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(1) a:hover {
  color: #db2777;
}
.mega-grid > .mega-section:nth-child(1) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(1) a:hover::before {
  color: #db2777;
}

/* ---- 2. Health Tools — red / squircle ---- */
.mega-grid > .mega-section:nth-child(2),
.mobile-tools-sections > .mobile-tool-section:nth-child(2) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#fef2f2, #fef2f2), linear-gradient(135deg, #fecaca, #fca5a5);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(2) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(2) h4 {
  color: #b91c1c;
  border-bottom-color: #fecaca;
}
.mega-grid > .mega-section:nth-child(2)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(2)::before {
  background: linear-gradient(180deg, #f87171, #dc2626);
}
.mega-grid > .mega-section:nth-child(2) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(2) h4 i {
  background: linear-gradient(135deg, #f87171, #dc2626);
  border-radius: 32%;
}
.mega-grid > .mega-section:nth-child(2):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(2):hover {
  box-shadow: 0 6px 20px rgba(220, 38, 38, 0.16);
}
.mega-grid > .mega-section:nth-child(2) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(2) a:hover {
  color: #dc2626;
}
.mega-grid > .mega-section:nth-child(2) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(2) a:hover::before {
  color: #dc2626;
}

/* ---- 3. Finance Calculator — amber / diamond ---- */
.mega-grid > .mega-section:nth-child(3),
.mobile-tools-sections > .mobile-tool-section:nth-child(3) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#fffbeb, #fffbeb), linear-gradient(135deg, #fde68a, #fcd34d);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(3) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(3) h4 {
  color: #92400e;
  border-bottom-color: #fde68a;
}
.mega-grid > .mega-section:nth-child(3)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(3)::before {
  background: linear-gradient(180deg, #fbbf24, #d97706);
}
.mega-grid > .mega-section:nth-child(3) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(3) h4 i {
  background: linear-gradient(135deg, #fbbf24, #d97706);
  border-radius: 5px;
  transform: rotate(45deg);
}
.mega-grid > .mega-section:nth-child(3) h3 i::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(3) h4 i::before {
  display: inline-block;
  transform: rotate(-45deg);
}
.mega-grid > .mega-section:nth-child(3):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(3):hover {
  box-shadow: 0 6px 20px rgba(217, 119, 6, 0.16);
}
.mega-grid > .mega-section:nth-child(3) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(3) a:hover {
  color: #d97706;
}
.mega-grid > .mega-section:nth-child(3) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(3) a:hover::before {
  color: #d97706;
}

/* ---- 4. Trading Calculator — blue / hexagon ---- */
.mega-grid > .mega-section:nth-child(4),
.mobile-tools-sections > .mobile-tool-section:nth-child(4) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#eff6ff, #eff6ff), linear-gradient(135deg, #bfdbfe, #93c5fd);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(4) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(4) h4 {
  color: #1d4ed8;
  border-bottom-color: #bfdbfe;
}
.mega-grid > .mega-section:nth-child(4)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(4)::before {
  background: linear-gradient(180deg, #60a5fa, #2563eb);
}
.mega-grid > .mega-section:nth-child(4) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(4) h4 i {
  background: linear-gradient(135deg, #60a5fa, #2563eb);
  clip-path: polygon(25% 0%, 75% 0%, 100% 50%, 75% 100%, 25% 100%, 0% 50%);
}
.mega-grid > .mega-section:nth-child(4):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(4):hover {
  box-shadow: 0 6px 20px rgba(37, 99, 235, 0.16);
}
.mega-grid > .mega-section:nth-child(4) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(4) a:hover {
  color: #2563eb;
}
.mega-grid > .mega-section:nth-child(4) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(4) a:hover::before {
  color: #2563eb;
}

/* ---- 5. Forex Calculator — violet / circle ---- */
.mega-grid > .mega-section:nth-child(5),
.mobile-tools-sections > .mobile-tool-section:nth-child(5) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#f5f3ff, #f5f3ff), linear-gradient(135deg, #ddd6fe, #c4b5fd);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(5) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(5) h4 {
  color: #6d28d9;
  border-bottom-color: #ddd6fe;
}
.mega-grid > .mega-section:nth-child(5)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(5)::before {
  background: linear-gradient(180deg, #a78bfa, #7c3aed);
}
.mega-grid > .mega-section:nth-child(5) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(5) h4 i {
  background: linear-gradient(135deg, #a78bfa, #7c3aed);
  border-radius: 50%;
}
.mega-grid > .mega-section:nth-child(5):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(5):hover {
  box-shadow: 0 6px 20px rgba(124, 58, 237, 0.16);
}
.mega-grid > .mega-section:nth-child(5) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(5) a:hover {
  color: #7c3aed;
}
.mega-grid > .mega-section:nth-child(5) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(5) a:hover::before {
  color: #7c3aed;
}

/* ---- 6. Crypto Tools — orange / squircle ---- */
.mega-grid > .mega-section:nth-child(6),
.mobile-tools-sections > .mobile-tool-section:nth-child(6) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#fff7ed, #fff7ed), linear-gradient(135deg, #fed7aa, #fdba74);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(6) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(6) h4 {
  color: #c2410c;
  border-bottom-color: #fed7aa;
}
.mega-grid > .mega-section:nth-child(6)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(6)::before {
  background: linear-gradient(180deg, #fb923c, #ea580c);
}
.mega-grid > .mega-section:nth-child(6) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(6) h4 i {
  background: linear-gradient(135deg, #fb923c, #ea580c);
  border-radius: 32%;
}
.mega-grid > .mega-section:nth-child(6):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(6):hover {
  box-shadow: 0 6px 20px rgba(234, 88, 12, 0.16);
}
.mega-grid > .mega-section:nth-child(6) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(6) a:hover {
  color: #ea580c;
}
.mega-grid > .mega-section:nth-child(6) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(6) a:hover::before {
  color: #ea580c;
}

/* ---- 7. Crypto Calculator — cyan / diamond ---- */
.mega-grid > .mega-section:nth-child(7),
.mobile-tools-sections > .mobile-tool-section:nth-child(7) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#ecfeff, #ecfeff), linear-gradient(135deg, #a5f3fc, #67e8f9);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(7) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(7) h4 {
  color: #0e7490;
  border-bottom-color: #a5f3fc;
}
.mega-grid > .mega-section:nth-child(7)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(7)::before {
  background: linear-gradient(180deg, #22d3ee, #0891b2);
}
.mega-grid > .mega-section:nth-child(7) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(7) h4 i {
  background: linear-gradient(135deg, #22d3ee, #0891b2);
  border-radius: 5px;
  transform: rotate(45deg);
}
.mega-grid > .mega-section:nth-child(7) h3 i::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(7) h4 i::before {
  display: inline-block;
  transform: rotate(-45deg);
}
.mega-grid > .mega-section:nth-child(7):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(7):hover {
  box-shadow: 0 6px 20px rgba(8, 145, 178, 0.16);
}
.mega-grid > .mega-section:nth-child(7) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(7) a:hover {
  color: #0891b2;
}
.mega-grid > .mega-section:nth-child(7) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(7) a:hover::before {
  color: #0891b2;
}

/* ---- 8. Astrology Self Discovery — fuchsia / hexagon ---- */
.mega-grid > .mega-section:nth-child(8),
.mobile-tools-sections > .mobile-tool-section:nth-child(8) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#fdf4ff, #fdf4ff), linear-gradient(135deg, #f5d0fe, #f0abfc);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(8) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(8) h4 {
  color: #a21caf;
  border-bottom-color: #f0abfc;
}
.mega-grid > .mega-section:nth-child(8)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(8)::before {
  background: linear-gradient(180deg, #e879f9, #c026d3);
}
.mega-grid > .mega-section:nth-child(8) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(8) h4 i {
  background: linear-gradient(135deg, #e879f9, #c026d3);
  clip-path: polygon(25% 0%, 75% 0%, 100% 50%, 75% 100%, 25% 100%, 0% 50%);
}
.mega-grid > .mega-section:nth-child(8):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(8):hover {
  box-shadow: 0 6px 20px rgba(192, 38, 211, 0.16);
}
.mega-grid > .mega-section:nth-child(8) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(8) a:hover {
  color: #c026d3;
}
.mega-grid > .mega-section:nth-child(8) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(8) a:hover::before {
  color: #c026d3;
}

/* ---- 9. Education Tools — lime / circle ---- */
.mega-grid > .mega-section:nth-child(9),
.mobile-tools-sections > .mobile-tool-section:nth-child(9) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#f7fee7, #f7fee7), linear-gradient(135deg, #d9f99d, #bef264);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(9) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(9) h4 {
  color: #4d7c0f;
  border-bottom-color: #d9f99d;
}
.mega-grid > .mega-section:nth-child(9)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(9)::before {
  background: linear-gradient(180deg, #a3e635, #65a30d);
}
.mega-grid > .mega-section:nth-child(9) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(9) h4 i {
  background: linear-gradient(135deg, #a3e635, #65a30d);
  border-radius: 50%;
}
.mega-grid > .mega-section:nth-child(9):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(9):hover {
  box-shadow: 0 6px 20px rgba(101, 163, 13, 0.16);
}
.mega-grid > .mega-section:nth-child(9) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(9) a:hover {
  color: #65a30d;
}
.mega-grid > .mega-section:nth-child(9) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(9) a:hover::before {
  color: #65a30d;
}

/* ---- 10. Math & Statistics Tools — sky / squircle ---- */
.mega-grid > .mega-section:nth-child(10),
.mobile-tools-sections > .mobile-tool-section:nth-child(10) {
  border: 1px solid transparent;
  background-image:
    linear-gradient(#f0f9ff, #f0f9ff), linear-gradient(135deg, #bae6fd, #7dd3fc);
  background-origin: border-box;
  background-clip: padding-box, border-box;
}
.mega-grid > .mega-section:nth-child(10) h3,
.mobile-tools-sections > .mobile-tool-section:nth-child(10) h4 {
  color: #075985;
  border-bottom-color: #bae6fd;
}
.mega-grid > .mega-section:nth-child(10)::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(10)::before {
  background: linear-gradient(180deg, #38bdf8, #0284c7);
}
.mega-grid > .mega-section:nth-child(10) h3 i,
.mobile-tools-sections > .mobile-tool-section:nth-child(10) h4 i {
  background: linear-gradient(135deg, #38bdf8, #0284c7);
  border-radius: 32%;
}
.mega-grid > .mega-section:nth-child(10):hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(10):hover {
  box-shadow: 0 6px 20px rgba(2, 132, 199, 0.16);
}
.mega-grid > .mega-section:nth-child(10) a:hover,
.mobile-tools-sections > .mobile-tool-section:nth-child(10) a:hover {
  color: #0284c7;
}
.mega-grid > .mega-section:nth-child(10) a:hover::before,
.mobile-tools-sections > .mobile-tool-section:nth-child(10) a:hover::before {
  color: #0284c7;
}

.mobile-menu::-webkit-scrollbar {
  width: 4px;
}
.mobile-menu::-webkit-scrollbar-thumb {
  background: #d1fae5;
  border-radius: 20px;
}

/* =========================================================
   SEARCH OVERLAY
========================================================= */

.search-overlay {
  position: fixed;
  inset: 0;
  background: rgba(15, 27, 53, 0.7);
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  z-index: 9000;
  display: flex;
  align-items: flex-start;
  justify-content: center;
  padding-top: 80px;
  opacity: 0;
  visibility: hidden;
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}

.search-overlay.active {
  opacity: 1;
  visibility: visible;
}

/* =========================================================
   SEARCH MODAL
========================================================= */

.search-modal {
  width: 100%;
  max-width: 750px;
  background: #ffffff;
  border-radius: 20px;
  border: 1px solid #e0eaff;
  box-shadow:
    0 32px 80px rgba(15, 27, 53, 0.22),
    0 4px 16px rgba(0, 0, 0, 0.08);
  overflow: hidden;
  transform: translateY(-16px) scale(0.98);
  transition: transform 0.28s cubic-bezier(0.34, 1.56, 0.64, 1);
  margin: 0 16px;
}

.search-overlay.active .search-modal {
  transform: translateY(0) scale(1);
}

/* =========================================================
   SEARCH INPUT ROW
========================================================= */

.search-input-row {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid #f0f4ff;
  background: #ffffff;
}

.search-input-icon {
  color: #0ea87a;
  font-size: 16px;
  flex-shrink: 0;
}

.search-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 15px;
  font-weight: 500;
  color: #0f172a;
  background: transparent;
  font-family: inherit;
  min-width: 0;
}

.search-input::placeholder {
  color: #9ca3af;
  font-weight: 400;
}

.search-clear {
  width: 26px;
  height: 26px;
  background: #f1f5f9;
  border: none;
  border-radius: 6px;
  color: #6b7280;
  font-size: 12px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition:
    background 0.2s ease,
    color 0.2s ease;
}

.search-clear:hover {
  background: #fee2e2;
  color: #dc2626;
}

.search-close-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f1f5f9;
  border: 1px solid #e2e8f0;
  border-radius: 7px;
  padding: 4px 9px;
  font-size: 11px;
  font-weight: 600;
  color: #6b7280;
  cursor: pointer;
  font-family: inherit;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.search-close-btn:hover {
  background: #e2e8f0;
  color: #374151;
}

/* =========================================================
   SEARCH CATEGORY PILLS
========================================================= */

.search-categories {
  padding: 12px 16px;
  border-bottom: 1px solid #f0f4ff;
  background: #fafbff;
}

.search-cat-label {
  display: block;
  font-size: 10.5px;
  font-weight: 700;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 8px;
}

.search-cat-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.cat-pill {
  display: inline-flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 20px;
  padding: 4px 12px;
  font-size: 11.5px;
  font-weight: 600;
  color: #6b7280;
  cursor: pointer;
  font-family: inherit;
  transition: all 0.2s ease;
}

.cat-pill:hover {
  border-color: #a7f3d0;
  color: #0ea87a;
  background: #f0fdf8;
}

.cat-pill.active {
  background: linear-gradient(135deg, #0ea87a, #059669);
  border-color: transparent;
  color: #ffffff;
  box-shadow: 0 3px 10px rgba(14, 168, 122, 0.3);
}

/* =========================================================
   SEARCH RESULTS
========================================================= */

.search-results {
  max-height: 360px;
  overflow-y: auto;
  padding: 14px 16px;
}

.search-results::-webkit-scrollbar {
  width: 5px;
}
.search-results::-webkit-scrollbar-thumb {
  background: #1dac75ce;
  border-radius: 20px;
}

.search-section {
  margin-bottom: 6px;
}

.search-section-title {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  color: #9ca3af;
  text-transform: uppercase;
  letter-spacing: 0.07em;
  margin-bottom: 10px;
}

.search-section-title i {
  color: #0ea87a;
  font-size: 11px;
}

/* =========================================================
   RESULTS GRID
========================================================= */

.search-results-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 8px;
}

/* =========================================================
   RESULT CARD
========================================================= */

.result-card {
  display: flex;
  align-items: center;
  gap: 9px;
  background: #f8faff;
  border: 1px solid #e8f0fe;
  border-radius: 11px;
  padding: 10px 12px;
  text-decoration: none;
  transition: all 0.2s ease;
  cursor: pointer;
}

.result-card:hover,
.result-card.focused {
  background: #f0fdf8;
  border-color: #a7f3d0;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(14, 168, 122, 0.1);
}

.result-card-icon {
  width: 30px;
  height: 30px;
  border-radius: 8px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  color: #0ea87a;
  flex-shrink: 0;
  transition: all 0.2s ease;
}

.result-card:hover .result-card-icon {
  background: linear-gradient(135deg, #0ea87a, #059669);
  border-color: transparent;
  color: #ffffff;
}

.result-card-info {
  min-width: 0;
  flex: 1;
}

.result-card-name {
  font-size: 12px;
  font-weight: 600;
  color: #0f172a;
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.result-card-cat {
  font-size: 10.5px;
  font-weight: 500;
  color: #9ca3af;
  margin-top: 1px;
}

.result-card:hover .result-card-name {
  color: #065f46;
}

/* =========================================================
   NO RESULTS
========================================================= */

.search-no-results {
  text-align: center;
  padding: 40px 20px;
}

.no-results-icon {
  font-size: 36px;
  color: #d1d5db;
  margin-bottom: 12px;
}

.no-results-title {
  font-size: 15px;
  font-weight: 700;
  color: #374151;
  margin-bottom: 6px;
}

.no-results-sub {
  font-size: 13px;
  color: #9ca3af;
}

/* =========================================================
   SEARCH FOOTER
========================================================= */

.search-footer {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 10px 16px;
  background: #fafbff;
  border-top: 1px solid #f0f4ff;
  font-size: 11px;
  font-weight: 500;
  color: #9ca3af;
  flex-wrap: wrap;
}

.search-footer i {
  font-size: 10px;
  margin-right: 3px;
}

.search-footer kbd {
  display: inline-flex;
  align-items: center;
  background: #ffffff;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  padding: 1px 5px;
  font-size: 10px;
  font-family: inherit;
  color: #6b7280;
}

.search-footer-right {
  margin-left: auto;
  color: #0ea87a;
  font-weight: 700;
}

/* =========================================================
   BREAKPOINT — 1400px
========================================================= */

@media (max-width: 1400px) {
  .mega-grid {
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }
}

/* =========================================================
   BREAKPOINT — 1200px
========================================================= */

@media (max-width: 1200px) {
  .mega-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

/* =========================================================
   BREAKPOINT — 1024px
========================================================= */

@media (max-width: 1024px) {
  .mega-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* =========================================================
   BREAKPOINT — 992px
========================================================= */

@media (max-width: 992px) {
  .mega-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

/* =========================================================
   BREAKPOINT — 768px  (MOBILE STARTS)
   Layout: [Logo] [—search bar—] [🔍][☰]
========================================================= */

@media (max-width: 768px) {
  .header-wrapper {
    min-height: 52px;
    gap: 8px;
  }

  /* hide desktop nav + desktop search button */
  .nav-menu {
    display: none;
  }
  .header-search-btn {
    display: none;
  }

  /* logo — left, slightly smaller */
  .mobile-menu-header .calculator-logo {
    width: auto;
    height: 30px;
    display: block;
  }
  .site-header .calculator-logo {
    height: 29px;
  }

  /* centre search bar — stretches to fill gap */
  .mobile-search-bar {
    display: flex;
  }

  /* right group: search icon + hamburger */
  .mobile-controls {
    display: flex;
  }

  /* hide standalone toggle (it lives inside .mobile-controls) */
  .mobile-menu-toggle {
    display: flex;
  }

  /* mobile menu full-screen on small devices */
  .mobile-menu {
    width: 300px;
    right: -300px;
  }

  .mobile-menu.active {
    right: 0;
  }

  /* search modal slides up from bottom on mobile */
  .search-overlay {
    padding-top: 20px;
    align-items: flex-start;
  }

  .search-modal {
    max-width: 100%;
    width: 100%;
    margin: 3px;
    border-radius: 22px 22px 22px 22px;
    border-left: none;
    border-right: none;
    border-bottom: none;
    transform: translateY(40px);
    max-height: 90vh;
    display: flex;
    flex-direction: column;
  }

  /* drag handle pill */
  .search-modal::before {
    content: "";
    display: block;
    width: 36px;
    height: 4px;
    background: #e2e8f0;
    border-radius: 20px;
    margin: 10px auto 0;
    flex-shrink: 0;
  }

  .search-overlay.active .search-modal {
    transform: translateY(0);
  }

  .search-results {
    flex: 1;
    max-height: none;
    overflow-y: auto;
  }

  .search-results-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 7px;
  }

  /* category pills scroll horizontally */
  .search-cat-pills {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 2px;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .search-cat-pills::-webkit-scrollbar {
    display: none;
  }
  .cat-pill {
    flex-shrink: 0;
  }
}

/* =========================================================
   BREAKPOINT — 480px
========================================================= */

@media (max-width: 480px) {
  .header-wrapper {
    gap: 10px;
  }

  .mobile-search-bar {
    padding: 6px 10px;
  }

  .mobile-search-bar span {
    font-size: 11.5px;
  }

  .mobile-menu-toggle {
    width: 32px;
    height: 32px;
    border-radius: 8px;
  }

  .mobile-controls {
    gap: 6px;
  }

  .mobile-menu {
    width: 100%;
    right: -100%;
  }

  .mobile-menu.active {
    right: 0;
  }

  .search-results-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 6px;
  }

  .search-input {
    font-size: 14px;
  }
  .result-card {
    padding: 8px 10px;
  }

  .result-card-icon {
    width: 26px;
    height: 26px;
    font-size: 11px;
    border-radius: 7px;
  }

  .result-card-name {
    font-size: 11px;
  }
  .result-card-cat {
    font-size: 10px;
  }
  .search-footer {
    display: none;
  }
}

/* =========================================================
   BREAKPOINT — 360px  (very small phones)
========================================================= */

@media (max-width: 360px) {
  .mobile-search-bar {
    padding: 5px 9px;
  }

  .mobile-search-bar i {
    font-size: 11px;
  }
  .mobile-search-bar span {
    font-size: 11px;
  }

  .mobile-menu-toggle {
    width: 30px;
    height: 30px;
    border-radius: 8px;
  }

  .mobile-controls {
    gap: 5px;
  }
}

/* ==============================================================================
   HEADER CSS END
   ============================================================================== */

/* ==============================================================================
   HERO CSS START
   ============================================================================== */

/* ── Hero Section ── */
.hero-section {
  margin-bottom: 24px;
}

.hero-box {
  position: relative;
  background: #ffffff;
  border: 1px solid #e0eaff;
  border-radius: 24px;
  padding: 36px 40px 32px;
  overflow: hidden;
  box-shadow:
    var(--shadow-md),
    inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

/* ── Gradient Orbs ── */
.orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
}
.orb-1 {
  width: 340px;
  height: 340px;
  top: -100px;
  right: -80px;
  background: radial-gradient(
    circle at 40% 40%,
    #bbf7e8 0%,
    #a7f3d0 35%,
    transparent 70%
  );
  opacity: 0.65;
}
.orb-2 {
  width: 280px;
  height: 280px;
  bottom: -100px;
  left: 30%;
  background: radial-gradient(
    circle at 50% 50%,
    #dbeafe 0%,
    #bfdbfe 40%,
    transparent 70%
  );
  opacity: 0.55;
}
.orb-3 {
  width: 140px;
  height: 140px;
  top: 40px;
  right: 280px;
  background: radial-gradient(circle, #ede9fe 0%, transparent 70%);
  opacity: 0.7;
}

/* ── Ambient floating shapes ── */
.floating-shapes {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
  z-index: 1;
}

.shape {
  position: absolute;
  display: block;
  animation: shapeDrift var(--dur, 9s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}

.shape-ring {
  width: var(--s, 30px);
  height: var(--s, 30px);
  border: 2.5px solid var(--c, #a7f3d0);
  border-radius: 50%;
  opacity: 0.5;
}
.shape-dot {
  width: var(--s, 10px);
  height: var(--s, 10px);
  background: var(--c, #93c5fd);
  border-radius: 50%;
  opacity: 0.55;
}
.shape-square {
  width: var(--s, 16px);
  height: var(--s, 16px);
  background: var(--c, #fbbf24);
  border-radius: 4px;
  transform: rotate(45deg);
  opacity: 0.4;
}
.shape-tri {
  width: 0;
  height: 0;
  border-left: calc(var(--s, 18px) / 2) solid transparent;
  border-right: calc(var(--s, 18px) / 2) solid transparent;
  border-bottom: var(--s, 18px) solid var(--c, #f9a8d4);
  opacity: 0.45;
}

.sh-1 {
  --s: 26px;
  --c: #6ee7b7;
  --dur: 10s;
  --delay: 0s;
  top: 14%;
  left: 6%;
}
.sh-2 {
  --s: 12px;
  --c: #60a5fa;
  --dur: 8s;
  --delay: 1.2s;
  top: 62%;
  left: 3%;
}
.sh-3 {
  --s: 16px;
  --c: #fbbf24;
  --dur: 11s;
  --delay: 0.6s;
  top: 8%;
  left: 38%;
}
.sh-4 {
  --s: 20px;
  --c: #f9a8d4;
  --dur: 9.5s;
  --delay: 2s;
  bottom: 10%;
  left: 16%;
}
.sh-5 {
  --s: 9px;
  --c: #a78bfa;
  --dur: 7.5s;
  --delay: 0.4s;
  top: 36%;
  left: 47%;
}

@keyframes shapeDrift {
  0%,
  100% {
    transform: translateY(0) rotate(0deg);
  }
  50% {
    transform: translateY(-14px) rotate(12deg);
  }
}

/* ── Layout: text + visual side by side ── */
.hero-inner {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  flex-wrap: wrap;
}

/* ── Text Content ── */
.hero-content {
  flex: 1 1 320px;
  max-width: 420px;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: linear-gradient(135deg, #d1fae5 0%, #a7f3d0 100%);
  color: #065f46;
  font-size: 11.5px;
  font-weight: 700;
  padding: 5px 12px 5px 9px;
  border-radius: 20px;
  margin-bottom: 12px;
  border: 1px solid #6ee7b7;
  letter-spacing: 0.01em;
}

.tag-dot {
  width: 7px;
  height: 7px;
  background: #0ea87a;
  border-radius: 50%;
  animation: blink 2s ease-in-out infinite;
}

@keyframes blink {
  0%,
  100% {
    opacity: 1;
    transform: scale(1);
  }
  50% {
    opacity: 0.45;
    transform: scale(1.35);
  }
}

.hero-h1 {
  font-size: 40px;
  font-weight: 800;
  color: var(--main-dark);
  line-height: 1.16;
  letter-spacing: -0.6px;
  margin-bottom: 11px;
}

.hero-h1 .accent {
  background: linear-gradient(130deg, #0ea87a 0%, #06b6d4 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-p {
  font-size: 13px;
  color: var(--main-pra);
  line-height: 1.72;
  margin-bottom: 18px;
  font-weight: 500;
  max-width: 360px;
}

.hero-btns {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: linear-gradient(135deg, #0ea87a 0%, #059669 100%);
  color: #fff;
  font-size: 13.5px;
  font-weight: 700;
  padding: 11px 22px;
  border-radius: 11px;
  cursor: pointer;
  border: none;
  box-shadow: 0 4px 14px rgba(14, 168, 122, 0.38);
  transition:
    transform 0.18s,
    box-shadow 0.18s;
  letter-spacing: 0.01em;
}
.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 22px rgba(14, 168, 122, 0.46);
}

.btn-ghost {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fff;
  color: #374151;
  font-size: 13.5px;
  font-weight: 600;
  padding: 11px 20px;
  border-radius: 11px;
  cursor: pointer;
  border: 1px solid #d1d5db;
  transition:
    transform 0.18s,
    border-color 0.18s,
    background 0.18s;
}
.btn-ghost:hover {
  border-color: #9ca3af;
  background: #f9fafb;
  transform: translateY(-2px);
}

/* ── Visual stage (illustration + connectors + badges) ── */
.hero-visual {
  position: relative;
  flex: 0 0 460px;
  width: 460px;
  height: 380px;
}

.connectors {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 1;
}

/* ── 3D illustration ── */
.illustration {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: 200px;
  height: 200px;
  z-index: 2;
}

.illu-glow {
  position: absolute;
  left: 50%;
  top: 58%;
  transform: translate(-50%, -50%);
  width: 210px;
  height: 110px;
  background: radial-gradient(
    ellipse at center,
    rgba(14, 168, 122, 0.28) 0%,
    transparent 72%
  );
  filter: blur(2px);
  animation: glowPulse 4s ease-in-out infinite;
}

@keyframes glowPulse {
  0%,
  100% {
    opacity: 0.7;
    transform: translate(-50%, -50%) scale(1);
  }
  50% {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1.08);
  }
}

.illu-ring {
  position: absolute;
  inset: -18px;
  border: 2px dashed rgba(14, 168, 122, 0.32);
  border-radius: 50%;
  animation: ringSpin 16s linear infinite;
}
.illu-ring::before,
.illu-ring::after {
  content: "";
  position: absolute;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #0ea87a;
  box-shadow: 0 0 0 3px #fff;
}
.illu-ring::before {
  top: -4px;
  left: calc(50% - 4px);
}
.illu-ring::after {
  top: 85.35%;
  left: 85.35%;
  transform: translate(-50%, -50%);
  background: #f59e0b;
}

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

.illu-card {
  position: absolute;
  left: 50%;
  top: 48%;
  transform: translate(-50%, -50%);
  width: 132px;
  height: 96px;
  border-radius: 16px;
  background: linear-gradient(150deg, #14b886 0%, #0c9469 65%, #0a8059 100%);
  box-shadow:
    5px 7px 0 #0a8059,
    9px 14px 0 #086e4c,
    0 18px 30px rgba(6, 95, 70, 0.38);
  padding: 12px 13px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.illu-card .illu-dots {
  display: flex;
  gap: 4px;
}
.illu-card .illu-dots span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.55);
}

.illu-bars {
  display: flex;
  align-items: flex-end;
  gap: 6px;
  height: 38px;
}
.illu-bars span {
  flex: 1;
  border-radius: 3px 3px 1px 1px;
  background: rgba(255, 255, 255, 0.85);
}
.illu-bars span:nth-child(1) {
  height: 40%;
  background: rgba(255, 255, 255, 0.55);
}
.illu-bars span:nth-child(2) {
  height: 65%;
  background: rgba(255, 255, 255, 0.72);
}
.illu-bars span:nth-child(3) {
  height: 50%;
  background: rgba(255, 255, 255, 0.62);
}
.illu-bars span:nth-child(4) {
  height: 92%;
  background: #ffffff;
}

.illu-symbol {
  position: absolute;
  top: -16px;
  right: -10px;
  width: 54px;
  height: 54px;
  border-radius: 50%;
  background: linear-gradient(140deg, #fde68a 0%, #f59e0b 60%, #d97706 100%);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
  font-weight: 800;
  color: #fff;
  box-shadow:
    3px 4px 0 #b45309,
    0 10px 18px rgba(217, 119, 6, 0.45);
  animation: symbolFloat 3.6s ease-in-out infinite;
  z-index: 3;
}

@keyframes symbolFloat {
  0%,
  100% {
    transform: translateY(0) rotate(-6deg);
  }
  50% {
    transform: translateY(-9px) rotate(6deg);
  }
}

/* ── Floating Feature Badges ── */
.bg-chips {
  position: absolute;
  inset: 0;
  pointer-events: none;
  z-index: 2;
}

.chip {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #ffffff;
  border: 1px solid #e5e7eb;
  border-radius: 14px;
  padding: 8px 14px 8px 9px;
  font-size: 12px;
  font-weight: 600;
  color: #374151;
  white-space: nowrap;
  box-shadow: 0 2px 14px rgba(0, 0, 0, 0.07);
  animation: chipFloat var(--dur, 5s) ease-in-out infinite;
  animation-delay: var(--delay, 0s);
}

@keyframes chipFloat {
  0%,
  100% {
    transform: translateY(0) rotate(var(--rot, 0deg));
  }
  50% {
    transform: translateY(-8px) rotate(var(--rot, 0deg));
  }
}

.chip-icon {
  width: 24px;
  height: 24px;
  border-radius: 7px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 12px;
  flex-shrink: 0;
}

/* chip icon background colors */
.ci-green {
  background: #d1fae5;
}
.ci-blue {
  background: #dbeafe;
}
.ci-amber {
  background: #fef3c7;
}
.ci-purple {
  background: #ede9fe;
}
.ci-rose {
  background: #ffe4e6;
}
.ci-teal {
  background: #ccfbf1;
}
.ci-indigo {
  background: #e0e7ff;
}
.ci-cyan {
  background: #cffafe;
}

/* chip positions (within the 460x380 visual stage) */
.chip-1 {
  top: 4px;
  left: 158px;
  --rot: -2deg;
  --dur: 5.2s;
  --delay: 0s;
}
.chip-2 {
  top: 54px;
  left: 332px;
  --rot: 1.5deg;
  --dur: 4.6s;
  --delay: 0.5s;
}
.chip-3 {
  top: 6px;
  left: 4px;
  --rot: 1.5deg;
  --dur: 5.6s;
  --delay: 0.9s;
}
.chip-4 {
  top: 152px;
  left: 348px;
  --rot: -1deg;
  --dur: 4.8s;
  --delay: 0.2s;
  border-color: #a7f3d0;
  box-shadow: 0 4px 18px rgba(14, 168, 122, 0.18);
}
.chip-5 {
  top: 232px;
  left: 350px;
  --rot: 2deg;
  --dur: 5.4s;
  --delay: 1.1s;
}
.chip-6 {
  top: 300px;
  left: 28px;
  --rot: -1.5deg;
  --dur: 5s;
  --delay: 0.7s;
}
.chip-7 {
  top: 350px;
  left: 168px;
  --rot: -0.5deg;
  --dur: 4.5s;
  --delay: 0.3s;
}
.chip-8 {
  top: 64px;
  left: 0px;
  --rot: 2deg;
  --dur: 5.8s;
  --delay: 1.4s;
}
.chip-9 {
  top: 196px;
  left: -8px;
  --rot: -2deg;
  --dur: 5.1s;
  --delay: 1.7s;
}

/* ── Stat Pills ── */
.stat-row {
  position: relative;
  z-index: 2;
  display: flex;
  flex-wrap: wrap;
  gap: 9px;
  margin-top: 22px;
  padding-top: 22px;
  border-top: 1px solid #f1f5f9;
}

.stat-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  background: #f8faff;
  border: 1px solid #e5e7eb;
  border-radius: 30px;
  padding: 5px 13px 5px 9px;
  font-size: 12px;
  font-weight: 600;
  color: #374151;
}

.pill-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  flex-shrink: 0;
}
.pd-green {
  background: #0ea87a;
}
.pd-blue {
  background: #3b82f6;
}
.pd-amber {
  background: #f59e0b;
}

/* ── Reduced motion ── */
@media (prefers-reduced-motion: reduce) {
  .hero-box * {
    animation: none !important;
    transition: none !important;
  }
}

/* ── Responsive ── */
@media (max-width: 980px) {
  .hero-inner {
    justify-content: center;
  }
  .hero-visual {
    margin: 0 auto;
  }
  .hero-btns {
    justify-content: center;
  }
  .hero-content {
    text-align: center;
  }
  .hero-p {
    max-width: 420px;
  }
}

@media (max-width: 700px) {
  .hero-visual {
    display: none;
  }
  .hero-content {
    max-width: none;
  }
}

@media (max-width: 560px) {
  .hero-box {
    padding: 32px 22px 28px;
  }
  .hero-h1 {
    font-size: 25px;
  }
  .floating-shapes {
    display: none;
  }
  .orb-1,
  .orb-2,
  .orb-3 {
    opacity: 0.3;
  }
}

/* ==============================================================================
   HERO CSS END
   ============================================================================== */

/* ==============================================================================
   SIDEBAR CSS START
   ============================================================================== */

/* =========================
   SIDEBAR
========================= */

/* =========================
   COMMON BOX
========================= */

.affiliate-box {
  width: 100%;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 20px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

/* =========================
   HEADING
========================= */

.sidebar-heading {
  margin-bottom: 0px;
  padding-bottom: 20px;
  border-bottom: 1px solid var(--border-color);
}

.sidebar-heading h3 {
  display: inline;
  padding: 7px 14px;
  padding-bottom: 9px;
  border-radius: 14px;
  background-color: var(--main-color);
  font-size: 20px;
  font-weight: 700;
  color: #fff;
}

/* =========================
   GOOGLE ADS
========================= */
.ad-box {
  width: 100%;
  background: #edf2f7;
  border: 2px dashed #cbd5e1;
  border-radius: var(--radius);
  min-height: 120px;
  align-items: center;
  justify-content: center;
  margin-block: 5px;
  margin: 0 auto;
  /*--------- after add display
willbe flax/block -------*/
  display: none;
}

.ad-box::after {
  content: "Ad";
  display: block;
  font-size: 10px;
  color: #adb5bd;
  padding: 4px;
  text-align: center;
  letter-spacing: 1px;
  text-transform: uppercase;
}

.google-ad-placeholder {
  width: 100%;
  min-height: 250px;
  border: 2px dashed var(--border-color);
  border-radius: 10px;
  align-items: center;
  justify-content: center;
  margin: 0 auto;
  background: #fafafa;
  /*--------- after add display willbe flax/block -------*/
  display: none;
}
/* =====================================================
   APPROVAL আগে — optional label দেখাতে চাইলে
   (নিজে দেখার জন্য, user দেখবে না)
===================================================== */
.google-ad-placeholder::after {
  content: "Ad";
  display: block;
  font-size: 10px;
  color: #adb5bd;
  padding: 4px;
  text-align: center;
  letter-spacing: 1px;
  text-transform: uppercase;
}
/* Approval পরে ins tag আসলে label সরে যাবে
   কারণ ins tag থাকলে ::after overlap করে না */

/* =========================
   SIDEBAR FIXED FOR PC
========================= */

.sidebar-area {
  position: sticky;
  top: 57px;

  height: fit-content;
}

/* ONLY PC SCREEN */

@media (max-width: 992px) {
  .sidebar-area {
    position: static;
    top: auto;
  }
}
/* =========================
   RESPONSIVE
========================= */

@media (max-width: 992px) {
  .sidebar-wrapper {
    gap: 20px;
  }
}

@media (max-width: 768px) {
  .affiliate-card {
    padding: 14px;
  }
}

/* ==============================================================================
   SIDEBAR CSS END
   ============================================================================== */

/* ==============================================================================
   ALL TOOLS CSS START
   ============================================================================== */

/* =========================================================
   TOOLS SECTION
========================================================= */

.tools-section {
  width: 100%;
  padding: 10px 0;
}

/* =========================================================
   FIX FLEX OVERFLOW
========================================================= */

.main-layout,
.content-area {
  min-width: 0;
}

/* =========================================================
   TOOLS NAVIGATION WRAPPER
========================================================= */

.tools-nav-wrapper {
  position: relative;

  display: flex;
  align-items: center;

  gap: 14px;

  width: 100%;

  margin-bottom: 25px;
}

/* =========================================================
   TOOLS NAVIGATION
========================================================= */

.tools-nav {
  flex: 1;

  overflow-x: auto;
  overflow-y: hidden;

  -webkit-overflow-scrolling: touch;

  scroll-behavior: smooth;

  padding-bottom: 0px;

  /* HIDE SCROLLBAR DEFAULT */
  scrollbar-width: none;
}

/* =========================================================
   SHOW SCROLLBAR ON HOVER
========================================================= */

/* =========================================================
   CHROME / EDGE / SAFARI
========================================================= */

.tools-nav::-webkit-scrollbar {
  display: none;
}

/* =========================================================
   TOOLS NAV INNER
========================================================= */

.tools-nav-inner {
  display: flex;
  align-items: center;
  gap: 5px;

  width: max-content;
  min-width: 100%;
}

/* =========================================================
   NAVIGATION ARROW BUTTON
========================================================= */

.tools-nav-arrow {
  width: 40px;
  height: 40px;

  border: none;
  outline: none;

  border-radius: 50%;

  background: var(--main-color);
  color: #ffffff;

  cursor: pointer;

  flex-shrink: 0;

  display: flex;
  align-items: center;
  justify-content: center;

  font-size: 15px;

  transition: 0.3s ease;
}

/* =========================================================
   CATEGORY BUTTON
========================================================= */

.cat-btn {
  flex-shrink: 0;

  border: none;
  outline: none;

  background: var(--main-ibg);
  color: var(--main-color);

  padding: 7px 20px;

  border-radius: 14px;

  cursor: pointer;

  white-space: nowrap;

  font-size: 15px;
  font-weight: 600;

  transition: 0.35s ease;
}

.cat-btn:hover {
  background: var(--main-color);
  color: #ffffff;
  transition: all 0.35s ease;
}

.cat-btn.active {
  background: var(--main-color);
  color: #ffffff;
  transition: all 0.35s ease;
}

/* =========================================================
   TOOL GRID
========================================================= */

.tool-grid {
  width: 100%;
}

/* =========================================================
   TOOL CATEGORY
========================================================= */

.tool-category {
  display: none;
}

.tool-category.active {
  display: grid;

  grid-template-columns: repeat(3, 1fr);

  gap: 15px;
}
/* =========================================================
   TOOL LINK RESET
========================================================= */

/* =========================================================
   TOOL CARD
========================================================= */

.tool-card {
  position: relative;
  background: #ffffff;
  border: 1px solid #e0eaff;
  border-left: 5px solid var(--main-color);
  border-radius: 16px;
  padding: 12px;
  overflow: hidden;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease,
    border-color 0.3s ease;

  /* subtle inner glow at rest — matches hero card language */
  box-shadow: 0 2px 10px rgba(37, 99, 235, 0.04);
}
.tool-card.tc1 {
  border-left-color: #f79494;
}
.tool-card.tc2 {
  border-left-color: #94f7a5;
}
.tool-card.tc3 {
  border-left-color: #cf94f7;
}
.tool-card.tc4 {
  border-left-color: #f7e094;
}
.tool-card.tc5 {
  border-left-color: #94f7d1;
}
.tool-card.tc6 {
  border-left-color: #f79494;
}
.tool-card.tc7 {
  border-left-color: #94f7a5;
}
.tool-card.tc8 {
  border-left-color: #cf94f7;
}
.tool-card.tc9 {
  border-left-color: #f7e094;
}
.tool-card.tc10 {
  border-left-color: #94f7d1;
}
/*icon*/
.tool-card.tc1 .tool-icon {
  color: #f56c6c;
}
.tool-card.tc2 .tool-icon {
  color: #6df884;
}
.tool-card.tc3 .tool-icon {
  color: #c16bfa;
}
.tool-card.tc4 .tool-icon {
  color: #f8d971;
}
.tool-card.tc5 .tool-icon {
  color: #6ef5c1;
}
.tool-card.tc6 .tool-icon {
  color: #f56c6c;
}
.tool-card.tc7 .tool-icon {
  color: #6df884;
}
.tool-card.tc8 .tool-icon {
  color: #c16bfa;
}
.tool-card.tc9 .tool-icon {
  color: #f8d971;
}
.tool-card.tc10 .tool-icon {
  color: #6ef5c1;
}
/* green mint orb that sweeps in on hover */
.tool-card::before {
  content: "";
  position: absolute;
  top: -60px;
  right: -60px;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(
    circle at 40% 40%,
    #bbf7e8 0%,
    #a7f3d0 40%,
    transparent 70%
  );
  opacity: 0.5;
  transition:
    opacity 0.35s ease,
    transform 0.35s ease;
  transform: scale(0.7);
  pointer-events: none;
}

/* blue orb at bottom-left */
.tool-card::after {
  content: "";
  position: absolute;
  bottom: -50px;
  left: -40px;
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: radial-gradient(circle, #dbeafe 0%, #bfdbfe 50%, transparent 75%);
  opacity: 0.5;
  transition:
    opacity 0.35s ease,
    transform 0.35s ease;
  transform: scale(0.7);
  pointer-events: none;
}

.tool-card:hover {
  transform: translateY(-5px);
  box-shadow:
    0 12px 32px rgba(14, 168, 122, 0.1),
    0 2px 8px rgba(37, 99, 235, 0.06);
  border-color: #a7f3d0;
}

.tool-card:hover::before {
  opacity: 0.7;
  transform: scale(1);
}

.tool-card:hover::after {
  opacity: 0.5;
  transform: scale(1);
}

/* =========================================================
   TOOL TOP
========================================================= */

.tool-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 12px;
}

/* =========================================================
   TOOL ICON
========================================================= */

.tool-icon {
  position: relative;
  z-index: 1;
  width: 42px;
  height: 42px;
  border-radius: 11px;
  background: #f0fdf8;
  border: 1px solid #d1fae5;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  color: #0ea87a;
  transition:
    transform 0.3s ease,
    background 0.3s ease,
    border-color 0.3s ease,
    box-shadow 0.3s ease;
}

.tool-card:hover .tool-icon {
  background: linear-gradient(135deg, #0ea87a 0%, #059669 100%);
  border-color: transparent;
  color: #ffffff;
  transform: rotate(-6deg) scale(1.08);
  box-shadow: 0 6px 16px rgba(14, 168, 122, 0.35);
}

.tool-card:hover .tool-icon i {
  transform: scale(1.08);
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.8));
  transition:
    transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
    filter 0.3s ease;
}

/* =========================================================
   TOOL ARROW
========================================================= */

.tool-arrow {
  position: relative;
  z-index: 1;
  font-size: 14px;
  color: #9ca3af;
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: #f8faff;
  border: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: center;
  transition:
    transform 0.3s ease,
    background 0.3s ease,
    color 0.3s ease,
    border-color 0.3s ease;
  scale: 1 ease;
}

.tool-card:hover .tool-arrow {
  transform: translateX(3px) scale(1.05);

  background: #0ea87a;
  border-color: #a7f3d0;
  color: #f0fdf8;
}

/* =========================================================
   TOOL TITLE
========================================================= */

.tool-title {
  position: relative;
  z-index: 1;
  font-size: 15px;
  font-weight: 700;
  color: var(--main-dark);
  line-height: 1.3;
  margin-bottom: 6px;
  transition: color 0.3s ease;
}

.tool-card:hover .tool-title {
  color: #065f46;
}

/* =========================================================
   TOOL DESCRIPTION
========================================================= */

.tool-desc {
  position: relative;
  z-index: 1;
  color: #6b7280;
  font-size: 13px;
  line-height: 1.4;
  font-weight: 500;
  margin-bottom: 0;
}

/* =========================================================
   CATEGORY HEADER
========================================================= */

.category-header {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 8px;
  margin-top: 12px;
}

/* =========================================================
   CATEGORY TITLE
========================================================= */

.category-title {
  flex-shrink: 0;
  font-size: 14px;
  font-weight: 700;
  color: #6b7280;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  line-height: 1.2;
}

/* =========================================================
   CATEGORY LINE
========================================================= */

.category-line {
  width: 100%;
  height: 1px;
  background: linear-gradient(to right, #d1fae5, #bfdbfe, transparent);
  border-radius: 50px;
}
/* =========================================================
   CATEGORY INLINE AD
========================================================= */

/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 768px) {
  .category-header {
    gap: 14px;
  }

  .category-title {
    font-size: 20px;
  }
}
/* =========================================================
   LAPTOP
========================================================= */

@media (max-width: 2400px) {
  .tool-category.active {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* =========================================================
   TABLET
========================================================= */

@media (max-width: 992px) {
  .tool-category.active {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* =========================================================
   MOBILE
========================================================= */

@media (max-width: 768px) {
  .tools-section {
    padding: 0px 0;
  }

  .tool-category.active {
    grid-template-columns: repeat(2, 1fr);

    gap: 18px;
  }

  .tool-card {
    padding: 20px;
  }

  .tool-title {
    font-size: 18px;
  }

  .tools-nav-arrow {
    display: none;
  }
}

/* =========================================================
   SMALL MOBILE
========================================================= */

@media (max-width: 576px) {
  .tool-category.active {
    grid-template-columns: 1fr;
  }

  .cat-btn {
    padding: 12px 18px;

    font-size: 14px;
  }
}

/* ==============================================================================
   ALL TOOLS CSS END
   ============================================================================== */

/* ==============================================================================
   POPULAR & RELATED TOOLS CSS START
   ============================================================================== */

/* =========================================================
   REGISTER CSS CUSTOM PROPERTIES
========================================================= */

@property --border-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

@property --icon-angle {
  syntax: "<angle>";
  inherits: false;
  initial-value: 0deg;
}

/* =========================================================
   INLINE TOOLS WRAPPER
========================================================= */

.inline-tools-wrapper {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
  margin-top: 20px;
}

/* =========================================================
   TOOLS CARD
========================================================= */

.tools-card {
  position: relative;
  border-radius: 20px;
  padding: 2px;
  overflow: visible;
  background: transparent;
  border: none;
  z-index: 0;
  box-shadow:
    0 4px 20px rgba(14, 168, 122, 0.06),
    0 1px 4px rgba(37, 99, 235, 0.04);
  transition:
    transform 0.35s ease,
    box-shadow 0.35s ease;

  --border-angle: 0deg;
  background-image: conic-gradient(
    from var(--border-angle),
    #0ea87a,
    #06b6d4,
    #3b82f6,
    #a78bfa,
    #ec4899,
    #f59e0b,
    #0ea87a
  );
  animation: border-rotate 4s linear infinite;
}

.tools-card:hover {
  transform: translateY(-5px);
  box-shadow:
    0 22px 55px rgba(14, 168, 122, 0.18),
    0 4px 14px rgba(37, 99, 235, 0.09);
  animation-duration: 1.5s;
}

@media (prefers-reduced-motion: reduce) {
  .tools-card {
    animation: none;
    background-image: none;
    border: 2px solid #a7f3d0;
  }
}

/* =========================================================
   BORDER ROTATE KEYFRAMES
========================================================= */

@keyframes border-rotate {
  to {
    --border-angle: 360deg;
  }
}

/* =========================================================
   TOOLS CARD INNER
========================================================= */

.tools-card-inner {
  position: relative;
  z-index: 1;
  background: #ffffff;
  border-radius: 18px;
  overflow: hidden;
  height: 100%;
}

/* green orb — top right */
.tools-card-inner::before {
  content: "";
  position: absolute;
  top: -60px;
  right: -60px;
  width: 180px;
  height: 180px;
  border-radius: 50%;
  background: radial-gradient(circle, #a7f3d0 0%, #6ee7b7 35%, transparent 70%);
  opacity: 0.18;
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
  pointer-events: none;
  z-index: 0;
}

/* blue orb — bottom left */
.tools-card-inner::after {
  content: "";
  position: absolute;
  bottom: -50px;
  left: -50px;
  width: 160px;
  height: 160px;
  border-radius: 50%;
  background: radial-gradient(circle, #bfdbfe 0%, #93c5fd 40%, transparent 70%);
  opacity: 0.15;
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
  pointer-events: none;
  z-index: 0;
}

.tools-card:hover .tools-card-inner::before {
  opacity: 0.55;
  transform: scale(1.2);
}

.tools-card:hover .tools-card-inner::after {
  opacity: 0.4;
  transform: scale(1.2);
}

/* =========================================================
   CARD HEADER
========================================================= */

.card-header {
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 18px 8px;
  background: linear-gradient(135deg, #f0fdf8 0%, #f8faff 100%);
  border-bottom: 1px solid #e0f2ee;
}

.card-header-left {
  display: flex;
  align-items: center;
  gap: 10px;
}

/* =========================================================
   ICON BG — base
========================================================= */

.icon-bg {
  position: relative;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
  --icon-angle: 0deg;
  z-index: 0;
}

/* =========================================================
   FIRE BG
========================================================= */

.fire-bg {
  background: conic-gradient(
    from var(--icon-angle),
    #0ea87a,
    #06b6d4,
    #34d399,
    #0ea87a
  );
  box-shadow:
    0 0 0 2px #ffffff,
    0 4px 14px rgba(14, 168, 122, 0.4);
  animation: icon-rotate 3s linear infinite;
}

/* =========================================================
   LINK BG
========================================================= */

.link-bg {
  background: conic-gradient(
    from var(--icon-angle),
    #3b82f6,
    #a78bfa,
    #06b6d4,
    #3b82f6
  );
  box-shadow:
    0 0 0 2px #ffffff,
    0 4px 14px rgba(59, 130, 246, 0.4);
  animation: icon-rotate 3s linear infinite;
}

/* =========================================================
   ICON ROTATE KEYFRAMES (conic bg spin)
========================================================= */

@keyframes icon-rotate {
  to {
    --icon-angle: 360deg;
  }
}

/* =========================================================
   INNER FILL (sits above spinning bg)
========================================================= */

.icon-bg::before {
  content: "";
  position: absolute;
  inset: 2.5px;
  border-radius: 8px;
  z-index: 1;
}

.fire-bg::before {
  background: linear-gradient(135deg, #0ea87a, #059669);
}

.link-bg::before {
  background: linear-gradient(135deg, #3b82f6, #2563eb);
}

/* =========================================================
   ICON — BASE
========================================================= */

.icon-bg i {
  position: relative;
  z-index: 2;
  color: #ffffff;
  font-size: 15px;
}

/* =========================================================
   FIRE ICON — Y-AXIS FLIP LOOP
========================================================= */

.fire-bg i {
  animation: icon-flip 2.4s ease-in-out infinite;
  transform-origin: center;
}

@keyframes icon-flip {
  0% {
    transform: rotateY(0deg) scale(1);
  }
  20% {
    transform: rotateY(90deg) scale(0.85);
  }
  40% {
    transform: rotateY(180deg) scale(1);
  }
  60% {
    transform: rotateY(270deg) scale(0.85);
  }
  80% {
    transform: rotateY(360deg) scale(1);
  }
  100% {
    transform: rotateY(360deg) scale(1);
  }
}

/* =========================================================
   LINK ICON — BOUNCY SPIN LOOP
========================================================= */

.link-bg i {
  animation: icon-spin-bounce 2.8s ease-in-out infinite;
  transform-origin: center;
}

@keyframes icon-spin-bounce {
  0% {
    transform: rotate(0deg) scale(1);
  }
  15% {
    transform: rotate(90deg) scale(1.15);
  }
  30% {
    transform: rotate(180deg) scale(1);
  }
  45% {
    transform: rotate(270deg) scale(1.15);
  }
  60% {
    transform: rotate(360deg) scale(1);
  }
  75% {
    transform: rotate(360deg) scale(1.1);
  }
  88% {
    transform: rotate(360deg) scale(0.92);
  }
  100% {
    transform: rotate(360deg) scale(1);
  }
}

/* =========================================================
   HOVER — cancels loop, applies snap effect
========================================================= */

.tools-card:hover .fire-bg i {
  animation: none;
  transform: scale(1.2) rotate(-10deg);
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.8));
  transition:
    transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
    filter 0.3s ease;
}

.tools-card:hover .link-bg i {
  animation: none;
  transform: scale(1.2) rotate(15deg);
  filter: drop-shadow(0 0 4px rgba(255, 255, 255, 0.8));
  transition:
    transform 0.4s cubic-bezier(0.34, 1.56, 0.64, 1),
    filter 0.3s ease;
}

.tools-card:hover .icon-bg {
  animation-duration: 1s;
}

.tools-card:hover .fire-bg {
  box-shadow:
    0 0 0 2px #ffffff,
    0 0 16px rgba(14, 168, 122, 0.6),
    0 6px 20px rgba(14, 168, 122, 0.5);
}

.tools-card:hover .link-bg {
  box-shadow:
    0 0 0 2px #ffffff,
    0 0 16px rgba(59, 130, 246, 0.6),
    0 6px 20px rgba(59, 130, 246, 0.5);
}

/* =========================================================
   HEADER TITLE
========================================================= */

.card-header h3 {
  font-size: 14.5px;
  font-weight: 800;
  color: #0f172a;
  line-height: 1.2;
  letter-spacing: -0.2px;
  transition: color 0.3s ease;
}

.tools-card:hover .card-header h3 {
  color: #065f46;
}

/* =========================================================
   COUNT BADGE
========================================================= */

.card-count {
  display: inline-flex;
  align-items: center;
  font-size: 10.5px;
  font-weight: 700;
  color: #065f46;
  background: linear-gradient(135deg, #d1fae5, #a7f3d0);
  border: 1px solid #6ee7b7;
  border-radius: 20px;
  padding: 3px 10px;
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.01em;
}

/* =========================================================
   TOOLS LIST
========================================================= */

.tools-list {
  position: relative;
  z-index: 2;
  max-height: 210px;
  overflow-y: auto;
  padding: 12px 14px 0 14px;
  mask-image: linear-gradient(to bottom, black 70%, transparent 100%);
  -webkit-mask-image: linear-gradient(to bottom, black 70%, transparent 100%);
}

/* =========================================================
   SCROLLBAR
========================================================= */

.tools-list::-webkit-scrollbar {
  width: 3px;
}
.tools-list::-webkit-scrollbar-track {
  background: transparent;
}
.tools-list::-webkit-scrollbar-thumb {
  background: linear-gradient(180deg, #0ea87a, #06b6d4);
  border-radius: 20px;
}

/* =========================================================
   LIST INNER
========================================================= */

.tools-list-inner {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding-bottom: 18px;
}

/* =========================================================
   TOOL LINK — base
========================================================= */

.tools-list a {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 36px;
  padding: 0 12px 0 14px;
  background: #f8faff;
  border: 1px solid #e8f0fe;
  border-radius: 10px;
  color: #475569;
  font-size: 12.5px;
  font-weight: 600;
  text-decoration: none;
  overflow: hidden;
  transition: all 0.22s ease;
  z-index: 1;
}

/* green fill sweep */
.tools-list a::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, #f0fdf8 0%, #d1fae5 100%);
  opacity: 0;
  transition: opacity 0.22s ease;
  z-index: -1;
}

/* icon + label */
.tools-list a span {
  display: inline-flex;
  align-items: center;
  gap: 9px;
  min-width: 0;
}

.tools-list a span i {
  font-size: 11px;
  color: #94a3b8;
  flex-shrink: 0;
  transition:
    color 0.22s ease,
    transform 0.22s ease;
}

/* arrow */
.tools-list a::after {
  content: "→";
  font-size: 13px;
  color: #cbd5e1;
  flex-shrink: 0;
  transition: all 0.22s ease;
  margin-left: 8px;
}

/* =========================================================
   TOOL LINK — hover
========================================================= */

.tools-list a:hover {
  background: transparent;
  border-color: #6ee7b7;
  color: #065f46;
  transform: translateX(4px);
  box-shadow: 0 2px 12px rgba(14, 168, 122, 0.12);
}

.tools-list a:hover::before {
  opacity: 1;
}

.tools-list a:hover span i {
  color: #0ea87a;
  transform: scale(1.15) rotate(-5deg);
}

.tools-list a:hover::after {
  color: #0ea87a;
  transform: translateX(3px);
}

/* =========================================================
   TOOL LINK — active
========================================================= */

.tools-list a:active {
  transform: translateX(2px) scale(0.99);
  box-shadow: 0 1px 6px rgba(14, 168, 122, 0.1);
}

/* =========================================================
   RESPONSIVE — 992px TABLET
========================================================= */

@media (max-width: 992px) {
  .inline-tools-wrapper {
    grid-template-columns: 1fr 1fr;
    gap: 12px;
  }

  .tools-card {
    border-radius: 18px;
  }
  .tools-card-inner {
    border-radius: 16px;
  }

  .card-header {
    padding: 14px 15px 12px;
  }
  .card-header h3 {
    font-size: 14px;
  }

  .icon-bg {
    width: 34px;
    height: 34px;
    border-radius: 10px;
  }
  .icon-bg::before {
    border-radius: 7px;
  }
  .fire-bg i,
  .link-bg i {
    font-size: 14px;
  }

  .tools-list {
    padding: 10px 12px 0;
    max-height: 195px;
  }
  .tools-list a {
    font-size: 12px;
    min-height: 34px;
    padding: 0 10px 0 12px;
  }
}

/* =========================================================
   RESPONSIVE — 768px LARGE MOBILE
========================================================= */

@media (max-width: 768px) {
  .inline-tools-wrapper {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }

  .tools-card {
    border-radius: 16px;
  }
  .tools-card-inner {
    border-radius: 14px;
  }

  .card-header {
    padding: 12px 13px 11px;
    gap: 8px;
  }
  .card-header h3 {
    font-size: 13px;
    letter-spacing: 0;
  }
  .card-count {
    font-size: 10px;
    padding: 2px 8px;
  }

  .icon-bg {
    width: 30px;
    height: 30px;
    border-radius: 9px;
  }
  .icon-bg::before {
    inset: 2px;
    border-radius: 6px;
  }
  .fire-bg i,
  .link-bg i {
    font-size: 13px;
  }

  .tools-list {
    padding: 9px 11px 0;
    max-height: 180px;
  }
  .tools-list a {
    font-size: 11.5px;
    min-height: 32px;
    padding: 0 9px 0 11px;
    border-radius: 9px;
  }
  .tools-list a span i {
    font-size: 10px;
  }
  .tools-list a::after {
    font-size: 12px;
  }
}

/* =========================================================
   RESPONSIVE — 576px MOBILE
========================================================= */

@media (max-width: 576px) {
  .inline-tools-wrapper {
    grid-template-columns: 1fr;
    gap: 10px;
  }

  .tools-card {
    border-radius: 16px;
    transform: none !important;
    animation-duration: 6s;
  }

  .tools-card-inner {
    border-radius: 14px;
  }

  .card-header {
    padding: 13px 14px 11px;
  }
  .card-header h3 {
    font-size: 13.5px;
  }

  .tools-list {
    padding: 10px 13px 0;
    max-height: 185px;
  }
  .tools-list a {
    font-size: 12px;
    min-height: 34px;
    padding: 0 10px 0 12px;
  }
  .tools-list a:hover {
    transform: none;
  }

  .tools-card:hover .tools-card-inner::before,
  .tools-card:hover .tools-card-inner::after {
    opacity: 0.2;
    transform: none;
  }
}

/* =========================================================
   RESPONSIVE — 360px SMALL MOBILE
========================================================= */

@media (max-width: 360px) {
  .tools-card-inner {
    border-radius: 12px;
  }

  .card-header {
    padding: 11px 12px 10px;
  }
  .card-count {
    display: none;
  }
  .card-header h3 {
    font-size: 13px;
  }

  .icon-bg {
    width: 28px;
    height: 28px;
    border-radius: 8px;
  }
  .icon-bg::before {
    inset: 2px;
    border-radius: 6px;
  }
  .fire-bg i,
  .link-bg i {
    font-size: 12px;
  }

  .tools-list {
    padding: 8px 10px 0;
    max-height: 170px;
  }
  .tools-list a {
    font-size: 11.5px;
    min-height: 31px;
    padding: 0 9px 0 10px;
    border-radius: 8px;
  }
  .tools-list a span {
    gap: 7px;
  }
  .tools-list a span i {
    font-size: 9.5px;
  }
}

/* ==============================================================================
   POPULAR & RELATED TOOLS CSS END
   ============================================================================== */

/* ==============================================================================
   AFFILIATE CSS START
   ============================================================================== */

/* =========================================================
   AFFILIATE CARD
========================================================= */

.affiliate-card {
  width: 100%;
  min-width: 0;
  overflow: hidden;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 0;
  margin-top: 10px;
  background: #ffffff;
  border-radius: 18px;
  padding: 14px 16px 0;
  text-decoration: none;
  overflow: hidden;
  transition:
    transform 0.35s ease,
    box-shadow 0.35s ease,
    border-color 0.35s ease;
  border: 1px solid #e0eaff;
  box-shadow: var(--shadow-sm);
}

.affiliate-card:hover {
  transform: translateY(-5px);
}

/* =========================================================
   ORB BLOBS
========================================================= */

.aff-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  transition:
    opacity 0.5s ease,
    transform 0.5s ease;
}

.aff-orb-1 {
  width: 160px;
  height: 160px;
  top: -65px;
  right: -55px;
  opacity: 0.4;
}
.aff-orb-2 {
  width: 120px;
  height: 120px;
  bottom: 24px;
  left: -45px;
  opacity: 0.28;
}

.affiliate-card:hover .aff-orb-1 {
  opacity: 0.72;
  transform: scale(1.18);
}
.affiliate-card:hover .aff-orb-2 {
  opacity: 0.52;
  transform: scale(1.22);
}

/* =========================================================
   TOP ROW — image + name + button all in one line
========================================================= */

.aff-top {
  min-width: 0;
  position: relative;
  z-index: 2;
  display: flex;
  align-items: center;
  gap: 10px;
  padding-bottom: 13px;
}

/* =========================================================
   ICON
========================================================= */

.aff-icon {
  flex-shrink: 0;
  width: 44px;
  height: 44px;
  padding: 5px;
  border-radius: 12px;
  border: 1px solid;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  transition:
    transform 0.35s ease,
    box-shadow 0.35s ease;
}

.aff-icon img {
  width: 100%;
  height: 100%;
  object-fit: contain;
}

.affiliate-card:hover .aff-icon {
  transform: rotate(-6deg) scale(1.1);
}

/* =========================================================
   NAME + SUBTITLE
========================================================= */

.aff-info {
  flex: 1;
  min-width: 0;
}

.aff-name {
  font-size: 14px;
  font-weight: 800;
  line-height: 1.15;
  margin: 0 0 2px;
  text-transform: uppercase;
  letter-spacing: 0.1rem;
}

.aff-sub {
  font-size: 11px;
  font-weight: 500;
  color: #9ca3af;

  line-height: 1.3;
  margin: 0;
}
.aff-name,
.aff-sub {
  overflow: hidden;
  text-overflow: ellipsis;
}

/* =========================================================
   JOIN NOW PILL
========================================================= */

.aff-join {
  flex-shrink: 0;
  font-size: 11.5px;
  font-weight: 700;
  color: #ffffff;
  border-radius: 20px;
  padding: 5px 10px;
  padding-left: 11px;
  letter-spacing: 0.02em;
  white-space: nowrap;
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.affiliate-card:hover .aff-join {
  transform: scale(1.05);
}

/* =========================================================
   TICKER STRIP
========================================================= */

.aff-ticker-wrap {
  position: relative;
  z-index: 2;
  margin: 0 -16px;
  padding: 0px 0;
  padding-bottom: 5px;
  overflow: hidden;
  white-space: nowrap;
}

/* smooth fade edges */
.aff-ticker-wrap::before,
.aff-ticker-wrap::after {
  content: "";
  position: absolute;
  top: 0;
  bottom: 0;
  width: 36px;
  z-index: 3;
  pointer-events: none;
}
.aff-ticker-wrap::before {
  left: 0;
}
.aff-ticker-wrap::after {
  right: 0;
}

/* separator dots between items */
.aff-ticker {
  display: inline-flex;
  align-items: center;
  gap: 0;
  white-space: nowrap;
  /* animation runs forever, no pause on hover */
  animation: ticker-loop 30s linear infinite;
  will-change: transform;
}

.aff-ticker span {
  display: inline-block;
  font-size: 11.5px;
  font-weight: 500;
  color: #6b7280;
  padding: 0 10px;
  position: relative;
}

/* bullet dot separator between items */
.aff-ticker span::after {
  content: "•";
  position: absolute;
  right: -2px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 10px;
  opacity: 0.35;
}

.aff-ticker strong {
  font-weight: 700;
}

/* =========================================================
   SEAMLESS LOOP — translates exactly 50% (3 items of 6)
   so it wraps back to start invisibly
========================================================= */

@keyframes ticker-loop {
  0% {
    transform: translate3d(0, 0, 0);
  }
  100% {
    transform: translate3d(-50%, 0, 0); /* Moves halfway for seamless looping */
  }
}

/* =========================================================
   BINANCE THEME
========================================================= */

.binance-card {
  border-color: #fef3c7;
}
.binance-card:hover {
  border-color: #fcd34d;
  box-shadow:
    0 16px 40px rgba(251, 191, 36, 0.14),
    0 2px 8px rgba(251, 191, 36, 0.07);
}
.binance-card .aff-orb-1 {
  background: radial-gradient(circle, #fef9c3 0%, #fde68a 50%, transparent 75%);
}
.binance-card .aff-orb-2 {
  background: radial-gradient(circle, #fef3c7 0%, #fcd34d 50%, transparent 75%);
}
.binance-card .aff-icon {
  background: #000000;
  border-color: #fde68a;
}
.binance-card:hover .aff-icon {
  border-color: #f59e0b;
  box-shadow: 0 6px 18px rgba(245, 158, 11, 0.28);
}
.binance-card .aff-name {
  color: #f0b90b;
}
.binance-card .aff-sub {
  color: #a78209;
}
.binance-card .aff-join {
  background: linear-gradient(135deg, #f0b90b 0%, #d97706 100%);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.35);
}
.binance-card .aff-ticker-wrap {
  background: linear-gradient(135deg, #fffbeb, #fef3c7);
  border-top: 1px solid #fde68a;
}
.binance-card .aff-ticker-wrap::before {
  background: linear-gradient(to right, #fffbeb, transparent);
}
.binance-card .aff-ticker-wrap::after {
  background: linear-gradient(to left, #fef3c7, transparent);
}
.binance-card .aff-ticker strong {
  color: #c79b09;
}

/* =========================================================
   EXNESS THEME
========================================================= */

.exness-card {
  border-color: #fef3c7;
}
.exness-card:hover {
  border-color: #fcd34d;
  box-shadow:
    0 16px 40px rgba(251, 191, 36, 0.14),
    0 2px 8px rgba(251, 191, 36, 0.07);
}
.exness-card .aff-orb-1 {
  background: radial-gradient(circle, #fef9c3 0%, #fde68a 50%, transparent 75%);
}
.exness-card .aff-orb-2 {
  background: radial-gradient(circle, #fef3c7 0%, #fcd34d 50%, transparent 75%);
}
.exness-card .aff-icon {
  background: #ffde02;
  border-color: #fde68a;
}
.exness-card:hover .aff-icon {
  border-color: #f59e0b;
  box-shadow: 0 6px 18px rgba(245, 158, 11, 0.28);
}
.exness-card .aff-name {
  color: #ffde02;
}
.exness-card .aff-sub {
  color: #9c8700;
}
.exness-card .aff-join {
  background: linear-gradient(135deg, #ffde02 0%, #d97706 100%);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.35);
}
.exness-card .aff-ticker-wrap {
  background: linear-gradient(135deg, #fffbeb, #fef3c7);
  border-top: 1px solid #fde68a;
}
.exness-card .aff-ticker-wrap::before {
  background: linear-gradient(to right, #fffbeb, transparent);
}
.exness-card .aff-ticker-wrap::after {
  background: linear-gradient(to left, #fef3c7, transparent);
}
.exness-card .aff-ticker strong {
  color: #ccb102;
}
/* =========================================================
   BITGET THEME
========================================================= */

.bitget-card {
  border-color: #d1fae5;
}
.bitget-card:hover {
  border-color: #6ee7b7;
  box-shadow:
    0 16px 40px rgba(14, 168, 122, 0.13),
    0 2px 8px rgba(14, 168, 122, 0.07);
}
.bitget-card .aff-orb-1 {
  background: radial-gradient(circle, #d1fae5 0%, #6ee7b7 50%, transparent 75%);
}
.bitget-card .aff-orb-2 {
  background: radial-gradient(circle, #ccfbf1 0%, #5eead4 50%, transparent 75%);
}
.bitget-card .aff-icon {
  background: #00f0ff;
  border-color: #a7f3d0;
}
.bitget-card:hover .aff-icon {
  border-color: #0ea87a;
  box-shadow: 0 6px 18px rgba(14, 168, 122, 0.28);
}
.bitget-card .aff-name {
  color: #00f0ff;
}
.bitget-card .aff-sub {
  color: #017c85;
}
.bitget-card .aff-join {
  background: linear-gradient(135deg, #00f0ff 0%, #059669 100%);
  box-shadow: 0 4px 12px rgba(14, 168, 122, 0.35);
}
.bitget-card .aff-ticker-wrap {
  background: linear-gradient(135deg, #f0fdf8, #d1fae5);
  border-top: 1px solid #a7f3d0;
}
.bitget-card .aff-ticker-wrap::before {
  background: linear-gradient(to right, #f0fdf8, transparent);
}
.bitget-card .aff-ticker-wrap::after {
  background: linear-gradient(to left, #d1fae5, transparent);
}
.bitget-card .aff-ticker strong {
  color: #0095a0;
}
/* =========================================================
   KUCOIN THEME
========================================================= */

.kucoin-card {
  border-color: #d1fae5;
}
.kucoin-card:hover {
  border-color: #6ee7b7;
  box-shadow:
    0 16px 40px rgba(14, 168, 122, 0.13),
    0 2px 8px rgba(14, 168, 122, 0.07);
}
.kucoin-card .aff-orb-1 {
  background: radial-gradient(circle, #d1fae5 0%, #6ee7b7 50%, transparent 75%);
}
.kucoin-card .aff-orb-2 {
  background: radial-gradient(circle, #ccfbf1 0%, #5eead4 50%, transparent 75%);
}
.kucoin-card .aff-icon {
  background: #fffbeb;
  border-color: #a7f3d0;
}
.kucoin-card:hover .aff-icon {
  border-color: #0ea87a;
  box-shadow: 0 6px 18px rgba(14, 168, 122, 0.28);
}
.kucoin-card .aff-name {
  color: #23af91;
}
.kucoin-card .aff-sub {
  color: #24aa8d;
}
.kucoin-card .aff-join {
  background: linear-gradient(135deg, #23af91 0%, #059669 100%);
  box-shadow: 0 4px 12px rgba(14, 168, 122, 0.35);
}
.kucoin-card .aff-ticker-wrap {
  background: linear-gradient(135deg, #f0fdf8, #d1fae5);
  border-top: 1px solid #a7f3d0;
}
.kucoin-card .aff-ticker-wrap::before {
  background: linear-gradient(to right, #f0fdf8, transparent);
}
.kucoin-card .aff-ticker-wrap::after {
  background: linear-gradient(to left, #d1fae5, transparent);
}
.kucoin-card .aff-ticker strong {
  color: #23af91;
}

/* =========================================================
   BITMART THEME
========================================================= */

.bitmart-card {
  border-color: #d1d5fa;
}
.bitmart-card:hover {
  border-color: #18181d;
  box-shadow:
    0 16px 40px rgba(7, 82, 59, 0.13),
    0 2px 8px rgba(5, 65, 47, 0.07);
}
.bitmart-card .aff-orb-1 {
  background: radial-gradient(circle, #d1fae5 0%, #18181d 50%, transparent 80%);
}
.bitmart-card .aff-orb-2 {
  background: radial-gradient(circle, #ccfbf1 0%, #18181d 50%, transparent 80%);
}
.bitmart-card .aff-icon {
  background: #18181d;
  border-color: black;
}
.bitmart-card:hover .aff-icon {
  border-color: #000000;
  box-shadow: 0 6px 18px rgba(7, 83, 60, 0.28);
}
.bitmart-card .aff-name {
  color: #18181d;
}
.bitmart-card .aff-sub {
  color: #33333d;
}
.bitmart-card .aff-join {
  background: linear-gradient(135deg, #7f7fa0 0%, #18181d 100%);
  box-shadow: 0 4px 12px rgba(6, 43, 68, 0.35);
}
.bitmart-card .aff-ticker-wrap {
  background: linear-gradient(135deg, #f0fdf8, #d4d1fa);
  border-top: 1px solid #acacc9;
}
.bitmart-card .aff-ticker-wrap::before {
  background: linear-gradient(to right, #f0f3fd, transparent);
}
.bitmart-card .aff-ticker-wrap::after {
  background: linear-gradient(to left, #d1dafa, transparent);
}
.bitmart-card .aff-ticker strong {
  color: #18181d;
}

/* =========================================================
   BYBIT THEME
========================================================= */

.bybit-card {
  border-color: #fef3c7;
}
.bybit-card:hover {
  border-color: #fcd34d;
  box-shadow:
    0 16px 40px rgba(251, 191, 36, 0.14),
    0 2px 8px rgba(251, 191, 36, 0.07);
}
.bybit-card .aff-orb-1 {
  background: radial-gradient(circle, #fef9c3 0%, #fde68a 50%, transparent 75%);
}
.bybit-card .aff-orb-2 {
  background: radial-gradient(circle, #fef3c7 0%, #fcd34d 50%, transparent 75%);
}
.bybit-card .aff-icon {
  background: #000000;
  border-color: #fde68a;
}
.bybit-card:hover .aff-icon {
  border-color: #f59e0b;
  box-shadow: 0 6px 18px rgba(245, 158, 11, 0.28);
}
.bybit-card .aff-name {
  color: #f0b90b;
}
.bybit-card .aff-sub {
  color: #a78209;
}
.bybit-card .aff-join {
  background: linear-gradient(135deg, #f0b90b 0%, #d97706 100%);
  box-shadow: 0 4px 12px rgba(245, 158, 11, 0.35);
}
.bybit-card .aff-ticker-wrap {
  background: linear-gradient(135deg, #fffbeb, #fef3c7);
  border-top: 1px solid #fde68a;
}
.bybit-card .aff-ticker-wrap::before {
  background: linear-gradient(to right, #fffbeb, transparent);
}
.bybit-card .aff-ticker-wrap::after {
  background: linear-gradient(to left, #fef3c7, transparent);
}
.bybit-card .aff-ticker strong {
  color: #c79b09;
}
/* =========================================================
   SIDEBAR DEFAULT (PC)
========================================================= */

.sidebar-wrapper {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
/* =========================================================
   GATE THEME
========================================================= */

.gate-card {
  border-color: #d1dafa;
}
.gate-card:hover {
  border-color: #0553fa;
  box-shadow:
    0 16px 40px rgba(17, 14, 168, 0.13),
    0 2px 8px rgba(14, 168, 122, 0.07);
}
.gate-card .aff-orb-1 {
  background: radial-gradient(circle, #d1fae5 0%, #0553fa 50%, transparent 75%);
}
.gate-card .aff-orb-2 {
  background: radial-gradient(
    circle,
    #ccfbf1 0%,
    #0553faef 50%,
    transparent 75%
  );
}
.gate-card .aff-icon {
  background: #0553fa;
  border-color: #0553fa;
}
.gate-card:hover .aff-icon {
  border-color: #022d8a;
  box-shadow: 0 6px 18px rgba(14, 17, 168, 0.28);
}
.gate-card .aff-name {
  color: #0553fa;
}
.gate-card .aff-sub {
  color: #033aaf;
}
.gate-card .aff-join {
  background: linear-gradient(135deg, #5087ff 0%, #0407c0 100%);
  box-shadow: 0 4px 12px rgba(14, 24, 168, 0.35);
}
.gate-card .aff-ticker-wrap {
  background: linear-gradient(135deg, #f0f1fd, #d1d4fa);
  border-top: 1px solid #a7a8f3;
}
.gate-card .aff-ticker-wrap::before {
  background: linear-gradient(to right, #f0f0fd, transparent);
}
.gate-card .aff-ticker-wrap::after {
  background: linear-gradient(to left, #d1d2fa, transparent);
}
.gate-card .aff-ticker strong {
  color: #0553fa;
}
/* =========================================================
   TABLET VIEW
   1024px AND BELOW
========================================================= */

@media (max-width: 1024px) {
  /* SIDEBAR FULL WIDTH */

  .sidebar-area {
    width: 100%;
    position: static;
  }

  /* AFFILIATE BOX */

  .affiliate-box {
    width: 100%;
  }

  /* CARD GRID */

  .affiliate-box {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
  }

  /* HEADING FULL WIDTH */

  .sidebar-heading {
    grid-column: 1 / -1;
  }
  .aff-name {
    font-weight: 700;
  }

  /* GOOGLE ADS FULL WIDTH */

  .google-box {
    grid-column: 1 / -1;
  }
  .affiliate-card {
    margin-top: 0;
  }
}
/* =========================================================
   900px → 2 CARDS
========================================================= */

/* =========================================================
   MOBILE VIEW
========================================================= */

@media (max-width: 768px) {
  .affiliate-box {
    grid-template-columns: repeat(2, 1fr);
  }
  .aff-name {
    font-weight: 800;
  }
}
@media (max-width: 576px) {
  .affiliate-box {
    grid-template-columns: repeat(1, 1fr);
  }
}
/* =========================
   1024px FIX
========================= */

@media (max-width: 1200px) {
  .main-layout {
    grid-template-columns: minmax(0, 1fr) 290px;
  }

  .aff-top {
    gap: 8px;
  }

  .aff-join {
    font-size: 10px;
    padding: 4px 8px;
    padding-left: 9px;
  }
}

/* =========================
   TABLET
========================= */

/* ==============================================================================
   AFFILIATE CSS END
   ============================================================================== */

/* ==============================================================================
   ADS CSS START
   ============================================================================== */

/* ==============================================================================
   ADS CSS END
   ============================================================================== */

/* ==============================================================================
   FOOTER CSS START
   ============================================================================== */

.site-footer {
  background: var(--main-dark);
  color: #fff;
  padding-top: 60px;
  margin-top: 60px;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 40px;
}

.footer-section h3 {
  font-size: 15px;
  margin-bottom: 0px;
  font-weight: 500;
}

.footer-text {
  font-size: 13px;
  line-height: 1.3;
  margin-bottom: 0px;
  font-weight: 500;
  color: #8d939c;
  margin: 10px 0px;
}

.footer-section ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-section ul li {
  margin-bottom: 4px;
}

.footer-section a {
  color: #8d939c;
  text-decoration: none;
  transition: 0.3s ease;
  font-size: 13px;
  font-weight: 500;
}

.footer-section li a:hover {
  color: var(--main-color);
  padding-left: 3px;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.social-links a {
  font-size: 1rem;
  color: #fff;
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  margin-top: 50px;
  padding: 25px 20px;
  text-align: center;
}

.footer-bottom p {
  margin: 0;
  font-size: 13px;
  color: #8d939c;
}

.social-links a:hover {
  opacity: 0.8;
  color: var(--main-color);
  padding-left: 0px;
  transform: scale(1.08);
}

.footer-section:last-child {
  padding-left: 40px;
  border-left: 1px solid rgba(255, 255, 255, 0.15);
}
.footer-grid {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr 3fr;
  gap: 40px;
}

.footer-section {
  min-width: 0;
}
.footer-logo .calculator-logo {
  display: block;
  width: auto;
  height: 37px;
}
/* Tablet */
@media (max-width: 992px) {
  .footer-grid {
    grid-template-columns: repeat(3, 1fr);
  }

  .footer-section:last-child {
    grid-column: 1 / -1;
  }
  .footer-section:last-child {
    border-left: none;
    border-top: 1px solid rgba(255, 255, 255, 0.15);
    padding-left: 0;
    padding-top: 20px;
  }
}

/* Mobile */
@media (max-width: 576px) {
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 35px;
  }

  .site-footer {
    padding-top: 45px;
  }

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

  .social-links {
    justify-content: center;
  }
  .footer-logo {
    display: inline-block;
    text-align: center;
  }
}
/* ==============================================================================
   FOOTER CSS END
   ============================================================================== */

/* ==============================================================================
   RESPONSIVE CSS START
   ============================================================================== */

@media (max-width: 1024px) {
  .main-layout {
    grid-template-columns: 1fr;
  }

  .sidebar-area {
    order: 2;
  }
}
@media (max-width: 992px) {
  .main-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  .header-wrapper {
    min-height: 60px;
  }

  .nav-menu {
    display: none;
  }

  .tool-grid {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 768px) {
  body {
    padding-top: 64px;
  }
}

/* ==============================================================================
   RESPONSIVE CSS END
   ============================================================================== */

/* ==============================================================================
   COOKIE CONSENT CSS START
   ============================================================================== */

/* =========================================================
   COOKIE CONSENT BAR — 100 Calculator
   Full-width bar that slides up from the bottom on first visit.
   Non-blocking: no dimmed backdrop, no scroll-lock, no focus
   trap — the page stays fully usable while it's showing.

   MERGED IN from a standalone cookie-consent.css that used to be
   linked separately by main.js and two direct <head> tags — see
   the MERGE NOTE at the end of this section for what to clean up.

   Class / ID prefix: ccm- (Cookie Consent Modal) — chosen to
   avoid any collision with the site's existing class names.

   § A  TOKENS       (light + dark color variables)
   § B  BAR WRAPPER  (fixed, bottom-anchored, slide-up transition)
   § C  BAR PANEL    (full-width card, minimum height)
   § D  CLOSE BUTTON
   § E  CONTENT      (badge, title, copy, links, status note)
   § F  ACTIONS      (Accept / Reject buttons)
   § G  RESPONSIVE   (mobile stacking)
   § H  MOTION SAFETY (prefers-reduced-motion)
========================================================= */

/* ---------- § A  TOKENS ---------- */
:root {
  --ccm-primary: #0ea87a; /* brand green — matches the site's theme-color */
  --ccm-primary-strong: #0a7d5c; /* button fill — verified 5.1:1 contrast with white text */
  --ccm-primary-strong-hover: #086b4d;
  --ccm-primary-tint: #e6f7f1; /* pale green — badge + status-note background */
  /* headings / primary text */
  /* body copy — 6.9:1 on white */
  --ccm-border: #d7e3de; /* secondary-button border */
  --ccm-radius: 16px; /* top corners only — bottom sits flush with the viewport edge */
  --ccm-ink: #eef7f4;
  --ccm-ink-soft: #adc0ba;
  --ccm-surface: #142420;
  --ccm-shadow:
    0 -16px 40px -12px rgba(0, 0, 0, 0.55), 0 -2px 10px rgba(0, 0, 0, 0.3);
  /* --ccm-primary-strong / -hover intentionally NOT overridden — the
       CTA button stays the same deep green in both themes as a brand
       anchor, and it keeps its verified AA contrast against white text. */
}

/* ---------- § B  BAR WRAPPER ---------- */
/* Deliberately NOT inset:0 — height is intrinsic to the bar's own content,
   so this wrapper only occupies the bottom strip where the bar lives and
   never covers/blocks the rest of the page above it. No backdrop dimming
   either: the person can read, click, and scroll everything else freely. */
.ccm-backdrop {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 999999;
  display: flex;
  justify-content: center;
  pointer-events: none;
  transform: translateY(100%);
  opacity: 0;
  transition:
    transform 3s cubic-bezier(0.22, 1, 0.36, 1),
    opacity 0.3s ease;
}

.ccm-backdrop.ccm-visible {
  transform: translateY(0);
  opacity: 1;
  pointer-events: auto;
}

/* ---------- § C  BAR PANEL ---------- */
.ccm-modal {
  position: relative; /* anchors the close button */
  width: 100%;
  max-width: 1800px; /* full-bleed on virtually every real screen; keeps
                         content from stretching absurdly thin on the rare
                         super-ultrawide monitor */
  min-height: 64px; /* stay compact — content drives the real height */
  max-height: 70vh;
  overflow-y: auto;
  background: var(--ccm-surface);
  border-radius: var(--ccm-radius) var(--ccm-radius) 0 0;
  box-shadow: var(--ccm-shadow);
  padding: 10px 56px 0px 26px;
  border-top: solid 5px var(--ccm-primary);
}

/* ---------- § D  CLOSE BUTTON ---------- */
.ccm-close {
  position: absolute;
  top: 12px;
  right: 14px;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  border: none;
  background: transparent;
  color: var(--ccm-ink-soft);
  font-size: 14px;
  line-height: 1;
  cursor: pointer;
  transition:
    background-color 0.15s ease,
    color 0.15s ease;
}

.ccm-close:hover {
  background: var(--ccm-primary-tint);
  color: var(--ccm-primary-strong);
}

.ccm-close:focus-visible {
  outline: 2.5px solid var(--ccm-primary-strong);
  outline-offset: 2px;
}

/* ---------- § E  CONTENT ---------- */
.ccm-body {
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: wrap;
}

.ccm-info {
  flex: 1 1 320px;
  min-width: 240px;
  max-height: fit-content;
}

.ccm-header {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 4px;
}

.ccm-badge {
  width: 30px;
  height: 30px;
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  background: var(--ccm-primary-tint);
  font-size: 16px;
  line-height: 1;
}

.ccm-title {
  margin: 0;
  font-size: 16.5px;
  font-weight: 700;
  color: var(--ccm-ink);
  letter-spacing: -0.01em;
}

.ccm-desc {
  margin: 0;
  font-size: 13.5px;
  line-height: 1.55;
  color: var(--ccm-ink-soft);
}

.ccm-link {
  color: var(--ccm-primary-strong);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 2px;
}

.ccm-link:hover,
.ccm-link:focus-visible {
  color: var(--ccm-primary-strong-hover);
}

.ccm-current {
  margin: 8px 0 0;
  padding: 6px 10px;
  border-radius: 8px;
  background: var(--ccm-primary-tint);
  color: var(--ccm-primary-strong);
  font-size: 12.5px;
  font-weight: 600;
  display: inline-block;
}

/* ---------- § F  ACTIONS ---------- */
.ccm-actions {
  display: flex;
  gap: 10px;
  flex-shrink: 0;
}

.ccm-btn {
  padding: 11px 18px;
  border-radius: 10px;
  font-size: 13.5px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border: 1.5px solid transparent;
  white-space: nowrap;
  transition:
    transform 0.15s ease,
    background-color 0.15s ease,
    border-color 0.15s ease,
    color 0.15s ease;
}

.ccm-btn:active {
  transform: scale(0.97);
}

.ccm-btn-primary {
  background: var(--ccm-primary-strong);
  color: #fff;
}

.ccm-btn-primary:hover {
  background: var(--ccm-primary-strong-hover);
}

.ccm-btn-secondary {
  background: transparent;
  color: var(--ccm-ink);
  border-color: var(--ccm-border);
}

.ccm-btn-secondary:hover {
  border-color: var(--ccm-primary-strong);
  color: var(--ccm-primary-strong);
}

.ccm-btn:focus-visible {
  outline: 2.5px solid var(--ccm-primary-strong);
  outline-offset: 2px;
}

/* ---------- § G  RESPONSIVE ---------- */
@media (max-width: 720px) {
  .ccm-body {
    flex-direction: column;
    align-items: stretch;
  }

  .ccm-modal {
    padding: 46px 20px 20px; /* extra top clearance for the close button */
  }

  .ccm-actions {
    width: 100%;
  }

  .ccm-actions .ccm-btn {
    flex: 1;
  }
}

/* ---------- § H  MOTION SAFETY ---------- */
@media (prefers-reduced-motion: reduce) {
  .ccm-backdrop,
  .ccm-btn,
  .ccm-close {
    transition: none !important;
  }
}

/* =========================================================
   MERGE NOTE
   This section used to live in its own /css/cookie-consent.css,
   loaded two ways:

     - main.js § 12 COOKIE CONSENT → ensureCookieConsentStyles()
       auto-injected a <link> on every page.
     - <link rel="stylesheet" href="/css/cookie-consent.css"> was
       also added directly in <head> on index.html and
       period-tracking.html for flash-free loading.

   Both are now redundant with this file and worth removing once
   you've confirmed style.css loads on every page these covered —
   otherwise the cookie bar's CSS just ships twice (harmless, just
   an extra request + parse). Nothing above depends on living in
   its own file, so it can still be split back out later if needed.
========================================================= */

/* ==============================================================================
   COOKIE CONSENT CSS END
   ============================================================================== */
