/* -------- TAMIM HEADER (polished version) -------- */
.t-header {
  position: sticky;
  top: 0;
  z-index: 9999;
  background: #ffffff;
  border-bottom: 1px solid #f1f5f9;
  padding: 12px 0;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.03);
}

.t-container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

.t-header__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

/* Logo */
.t-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 18px;
  color: #0f172a;
  text-decoration: none;
}
.t-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: #0f172a;
  color: #fff;
  font-weight: 700;
  font-size: 14px;
}

/* Menu */
.t-nav {
  display: flex;
  align-items: center;
  gap: 30px;
}
.t-menu {
  display: flex;
  gap: 28px;
  margin: 0;
  padding: 0;
  list-style: none;
}
.t-menu a {
  color: #111827;
  text-decoration: none;
  font-size: 15px;
  font-weight: 500;
  transition: color 0.2s;
}
.t-menu a:hover {
  color: #2563eb;
}

/* CTA button */
.t-cta {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 18px;
  border-radius: 14px;
  background: #111;
  color: #fff;
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  transition: background 0.2s;
}
.t-cta:hover {
  background: #2563eb;
}

/* Mobile menu */
.t-burger {
  display: none;
  background: none;
  border: 0;
  padding: 8px;
  cursor: pointer;
}
.t-burger svg {
  width: 26px;
  height: 26px;
  fill: #111;
}

@media (max-width: 900px) {
  .t-menu {
    display: none;
    position: absolute;
    top: 64px;
    right: 20px;
    background: #fff;
    border: 1px solid #e5e7eb;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(16, 24, 40, 0.08);
    flex-direction: column;
    width: 200px;
    padding: 16px;
  }
  .t-menu.is-open {
    display: flex;
  }
  .t-burger {
    display: inline-flex;
  }
  .t-cta {
    display: none;
  }
}
/* === Fix 1: Hide submenus until hover (desktop) === */
.t-menu > li { position: relative; }
.t-menu .sub-menu {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(16,24,40,.08);
  padding: 10px 0;
  min-width: 200px;
  z-index: 10000;
}
.t-menu li:hover > .sub-menu { display: block; }
.t-menu .sub-menu li { white-space: nowrap; }
.t-menu .sub-menu a {
  display: block;
  padding: 10px 14px;
  font-size: 14px;
  color: #111827;
}
.t-menu .sub-menu a:hover { background: #f8fafc; }

/* === Fix 2: Align menu items with CTA vertically === */
.t-nav { display: flex; align-items: center; gap: 30px; }
.t-menu { display: flex; align-items: center; gap: 28px; }
.t-menu a {
  display: inline-flex;          /* makes vertical centering reliable */
  align-items: center;           /* vertical center */
  height: 38px;                  /* match CTA-ish height */
  line-height: 1;                /* avoid extra vertical space */
  padding: 0 0;                  /* no extra top/bottom padding */
}

/* Mobile behavior: dropdowns inside the opened panel */
@media (max-width: 900px) {
  .t-menu { position: absolute; top: 64px; right: 20px; left: auto; width: 220px; }
  .t-menu .sub-menu {
    position: static;          /* stack in the panel */
    display: none;             /* hidden by default, toggled via JS below */
    border: 0; border-top: 1px solid #f1f5f9; border-radius: 0; box-shadow: none; padding: 6px 0 10px;
  }
  .t-menu .has-open > .sub-menu { display: block; }
  .t-menu > li { width: 100%; }
  .t-menu > li > a { width: 100%; padding: 10px 6px; height: auto; }
}
/* === Fix dropdown hover gap issue === */
.t-menu > li {
  position: relative;
}

/* Give a little overlap zone so hover doesn't break */
.t-menu > li:hover > .sub-menu,
.t-menu > li:focus-within > .sub-menu {
  display: block;
  visibility: visible;
  opacity: 1;
}

.t-menu .sub-menu {
  display: none;
  visibility: hidden;
  opacity: 0;
  transition: opacity 0.15s ease-in-out;
  position: absolute;
  top: 100%;       /* directly under parent */
  left: 0;
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(16,24,40,0.08);
  padding: 8px 0;
  min-width: 200px;
  z-index: 10000;
}

/* Submenu links styling */
.t-menu .sub-menu li {
  display: block;
}
.t-menu .sub-menu a {
  display: block;
  padding: 10px 16px;
  color: #111827;
  text-decoration: none;
  white-space: nowrap;
}
.t-menu .sub-menu a:hover {
  background: #f8fafc;
  color: #2563eb;
}
