/* ═══════════════════════════════════════════════════════════
   tc-header.css — TaxClue v1.0.4
   Upload to: your-theme/assets/css/tc-header.css
   ═══════════════════════════════════════════════════════════ */

:root {
    --tc-navy:    #0d1e3c;
    --tc-blue:    #1355c1;
    --tc-blue2:   #1a6af5;
    --tc-pink:    #e83e5a;
    --tc-accent:  #f5a623;
    --tc-light:   #f3f6fc;
    --tc-border:  #e2e8f4;
    --tc-gray:    #5a6e8a;
    --tc-white:   #ffffff;
    --tc-ann-h:   38px;
    --tc-hdr-h:   68px;
}

/* Body offset for fixed header */
body {
    padding-top: calc( var(--tc-ann-h) + var(--tc-hdr-h) ) !important;
}

/* ═══════════════════════════════════════════════════════════
   ANNOUNCEMENT BAR
═══════════════════════════════════════════════════════════ */
.tc-ann {
    position: fixed;
    top: 0; left: 0; right: 0;
    z-index: 10001;
    height: var(--tc-ann-h);
    background: var(--tc-navy);
    overflow: hidden;
    display: flex;
    align-items: center;
    transition: height .3s ease;
}

.tc-ann-track {
    display: flex;
    align-items: center;
    white-space: nowrap;
    flex-shrink: 0;
    animation: tc-scroll 35s linear infinite;
}
.tc-ann-track:hover { animation-play-state: paused; }

@keyframes tc-scroll {
    from { transform: translateX(0); }
    to   { transform: translateX(-50%); }
}

.tc-ann-track span {
    display: inline-flex;
    align-items: center;
    gap: 7px;
    padding: 0 24px;
    font-size: 12.5px;
    font-family: 'DM Sans', sans-serif;
    color: rgba(255,255,255,.9);
    flex-shrink: 0;
}
.tc-ann-track span b { color: var(--tc-accent); font-weight: 700; }

.tc-dot {
    display: inline-block;
    width: 4px; height: 4px;
    border-radius: 50%;
    background: rgba(255,255,255,.3);
    font-style: normal;
    vertical-align: middle;
    flex-shrink: 0;
}

.tc-ann-close {
    position: absolute;
    right: 14px; top: 50%;
    transform: translateY(-50%);
    background: none; border: none;
    color: rgba(255,255,255,.5);
    font-size: 15px; cursor: pointer;
    padding: 5px 8px; line-height: 1;
    z-index: 2;
    transition: color .2s;
}
.tc-ann-close:hover { color: #fff; }

/* ═══════════════════════════════════════════════════════════
   MAIN HEADER
═══════════════════════════════════════════════════════════ */
.tc-header {
    position: fixed;
    top: var(--tc-ann-h); left: 0; right: 0;
    z-index: 10000;
    height: var(--tc-hdr-h);
    background: var(--tc-white);
    border-bottom: 1px solid var(--tc-border);
    transition: box-shadow .25s, top .3s ease;
}
.tc-header.tc-scrolled { box-shadow: 0 4px 24px rgba(13,30,60,.1); }

.tc-header-inner {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    height: 100%;
    display: flex;
    align-items: center;
}

/* ── LOGO ── */
.tc-logo {
    display: flex;
    align-items: center;
    text-decoration: none;
    flex-shrink: 0;
    margin-right: 24px;
    outline: none;
}
.tc-logo-img {
    height: 38px;
    width: auto;
    display: block;
    object-fit: contain;
    max-width: 180px;
}
@media (max-width: 400px) {
    .tc-logo-img { height: 30px; max-width: 140px; }
}

/* ═══════════════════════════════════════════════════════════
   DESKTOP NAV  (1024px+)
═══════════════════════════════════════════════════════════ */
.tc-nav {
    display: none;
    height: 100%;
    flex: 1;
    overflow: visible;
}
@media (min-width: 1024px) {
    .tc-nav { display: flex; align-items: center; }
}

ul.tc-menu {
    list-style: none;
    margin: 0; padding: 0;
    display: flex;
    align-items: center;
    height: 100%;
}

/* Top-level nav item */
.tc-nav-item {
    position: relative;
    height: 100%;
    display: flex;
    align-items: center;
}

/* Top-level link or button */
.tc-nav-link {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 0 13px;
    height: 100%;
    font-size: 13.5px;
    font-weight: 600;
    font-family: 'DM Sans', sans-serif;
    color: var(--tc-navy);
    text-decoration: none;
    background: none;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    position: relative;
    transition: color .18s;
}
.tc-nav-link::after {
    content: '';
    position: absolute;
    bottom: 0; left: 13px; right: 13px;
    height: 2.5px;
    background: var(--tc-blue);
    border-radius: 2px 2px 0 0;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform .2s;
}
.tc-nav-item:hover > .tc-nav-link,
.tc-nav-item.tc-active > .tc-nav-link,
.tc-nav-item.tc-kb-open > .tc-nav-link { color: var(--tc-blue); }

.tc-nav-item:hover > .tc-nav-link::after,
.tc-nav-item.tc-active > .tc-nav-link::after,
.tc-nav-item.tc-kb-open > .tc-nav-link::after { transform: scaleX(1); }

.tc-caret {
    flex-shrink: 0;
    opacity: .5;
    transition: transform .22s;
    margin-left: 1px;
}
.tc-nav-item:hover .tc-caret,
.tc-nav-item.tc-kb-open .tc-caret { transform: rotate(180deg); opacity: .9; }

/* ═══════════════════════════════════════════════════════════
   DROPDOWN PANEL
   — If depth-1 items have children → MEGA COLUMNS appear
   — If depth-1 items have no children → simple list
═══════════════════════════════════════════════════════════ */
.tc-dd-panel {
    position: absolute;
    top: 100%; left: 0;
    background: var(--tc-white);
    border: 1px solid var(--tc-border);
    border-radius: 14px;
    box-shadow: 0 20px 56px rgba(13,30,60,.14);
    padding: 18px 20px;
    width: max-content;
    max-width: 860px;
    min-width: 180px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: opacity .22s, transform .22s, visibility .22s;
    pointer-events: none;
    z-index: 999;
    /* columns sit side by side */
    display: flex;
    flex-wrap: nowrap;
    gap: 0;
    align-items: flex-start;
}
.tc-nav-item:hover .tc-dd-panel,
.tc-nav-item.tc-kb-open .tc-dd-panel {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
    pointer-events: auto;
}

/* Simple link (depth-1, no children) */
.tc-dd-link {
    display: block;
    padding: 9px 12px;
    border-radius: 8px;
    font-size: 13.5px;
    font-weight: 600;
    font-family: 'DM Sans', sans-serif;
    color: var(--tc-navy);
    text-decoration: none;
    white-space: nowrap;
    width: 100%;
    transition: background .15s, color .15s;
}
.tc-dd-link:hover { background: var(--tc-light); color: var(--tc-blue); }

/* ═══════════════════════════════════════════════════════════
   MEGA COLUMNS  (depth-1 with children)
═══════════════════════════════════════════════════════════ */
.tc-col {
    flex: 0 0 auto;
    min-width: 170px;
    padding-right: 24px;
    margin-right: 24px;
    border-right: 1px solid var(--tc-border);
}
/* Last column: no right divider */
.tc-col:last-child {
    border-right: none;
    margin-right: 0;
    padding-right: 0;
}

/* Column header row — green globe icon like IndiaFilings */
.tc-col-head {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 10px;
    margin-bottom: 4px;
    border-bottom: 1.5px solid var(--tc-border);
}
.tc-col-head::before {
    content: '';
    display: inline-block;
    width: 18px; height: 18px;
    border-radius: 50%;
    background: radial-gradient(circle at 40% 38%, #4caf50, #1a7d1e);
    flex-shrink: 0;
    box-shadow: 0 1px 5px rgba(76,175,80,.4);
}
.tc-col-title {
    font-size: 13px;
    font-weight: 800;
    font-family: 'DM Sans', sans-serif;
    color: var(--tc-navy);
    text-decoration: none;
    white-space: nowrap;
    line-height: 1.2;
    transition: color .15s;
}
.tc-col-title:hover { color: var(--tc-blue); }

/* Items list */
.tc-col-list {
    list-style: none;
    margin: 0; padding: 0;
    display: flex;
    flex-direction: column;
}
.tc-col-item {
    display: block;
    padding: 7px 8px;
    border-radius: 6px;
    font-size: 13px;
    font-weight: 500;
    font-family: 'DM Sans', sans-serif;
    color: #374151;
    text-decoration: none;
    white-space: nowrap;
    transition: background .14s, color .14s;
    line-height: 1.35;
}
.tc-col-item:hover,
.tc-col-item--active { background: var(--tc-light); color: var(--tc-blue); }

/* No-menu fallback */
.tc-no-menu { padding: 0 13px; font-size: 13px; color: var(--tc-gray); }
.tc-no-menu a { color: var(--tc-blue); }

/* ═══════════════════════════════════════════════════════════
   RIGHT ACTIONS
═══════════════════════════════════════════════════════════ */
.tc-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-left: auto;
    flex-shrink: 0;
}

.tc-search-btn {
    width: 38px; height: 38px;
    background: var(--tc-light);
    border: 1.5px solid var(--tc-border);
    border-radius: 9px;
    display: grid; place-items: center;
    cursor: pointer;
    color: var(--tc-navy);
    flex-shrink: 0;
    transition: background .15s, border-color .15s, color .15s;
}
.tc-search-btn:hover { background: #e8f0fe; border-color: var(--tc-blue); color: var(--tc-blue); }

.tc-phone-link {
    display: none;
    align-items: center;
    gap: 6px;
    font-size: 13px; font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    color: var(--tc-navy);
    text-decoration: none;
    padding: 9px 13px;
    border-radius: 9px;
    border: 1.5px solid var(--tc-border);
    white-space: nowrap;
    flex-shrink: 0;
    transition: border-color .15s, color .15s;
}
.tc-phone-link:hover { border-color: var(--tc-blue); color: var(--tc-blue); }
@media (min-width: 768px) { .tc-phone-link { display: inline-flex; } }

.tc-cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    background: var(--tc-pink);
    color: #fff !important;
    font-size: 13px; font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    padding: 10px 18px;
    border-radius: 9px;
    text-decoration: none !important;
    border: none; cursor: pointer;
    white-space: nowrap; flex-shrink: 0;
    transition: transform .15s, box-shadow .15s;
}
.tc-cta-btn:hover { transform: translateY(-1px); box-shadow: 0 5px 18px rgba(232,62,90,.38); }

/* Hamburger */
.tc-hamburger {
    display: flex; flex-direction: column;
    justify-content: center; gap: 5px;
    width: 38px; height: 38px;
    background: var(--tc-light);
    border: 1.5px solid var(--tc-border);
    border-radius: 9px; cursor: pointer;
    padding: 9px; flex-shrink: 0;
}
@media (min-width: 1024px) { .tc-hamburger { display: none; } }
.tc-hamburger span {
    display: block; width: 100%; height: 2px;
    background: var(--tc-navy); border-radius: 2px;
    transition: transform .3s, opacity .3s, width .3s;
}
.tc-hamburger.tc-open span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.tc-hamburger.tc-open span:nth-child(2) { opacity: 0; width: 0; }
.tc-hamburger.tc-open span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ═══════════════════════════════════════════════════════════
   SEARCH OVERLAY
═══════════════════════════════════════════════════════════ */
.tc-search-overlay {
    position: fixed; inset: 0;
    z-index: 10002;
    background: rgba(13,30,60,.6);
    backdrop-filter: blur(5px);
    -webkit-backdrop-filter: blur(5px);
    display: flex; align-items: flex-start;
    justify-content: center; padding-top: 120px;
    opacity: 0; visibility: hidden;
    transition: opacity .22s, visibility .22s;
}
.tc-search-overlay.tc-active { opacity: 1; visibility: visible; }

.tc-search-box {
    background: #fff; border-radius: 16px;
    padding: 24px; width: 100%; max-width: 580px;
    margin: 0 16px;
    box-shadow: 0 24px 64px rgba(13,30,60,.22);
}
.tc-search-box > p {
    font-size: 11px; font-weight: 800; letter-spacing: 2px;
    text-transform: uppercase; color: var(--tc-gray);
    margin-bottom: 14px; font-family: 'DM Sans', sans-serif;
}
.tc-search-box .search-form { display: flex; gap: 10px; margin: 0; }
.tc-search-box .search-field {
    flex: 1; padding: 12px 16px;
    border: 2px solid var(--tc-border); border-radius: 9px;
    font-size: 15px; font-family: 'DM Sans', sans-serif;
    color: var(--tc-navy); background: var(--tc-light);
    outline: none; transition: border-color .2s, background .2s;
}
.tc-search-box .search-field:focus { border-color: var(--tc-blue); background: #fff; }
.tc-search-box .search-submit {
    padding: 12px 20px; background: var(--tc-blue); color: #fff;
    border: none; border-radius: 9px; font-size: 14px;
    font-weight: 700; font-family: 'DM Sans', sans-serif;
    cursor: pointer; transition: background .15s;
}
.tc-search-box .search-submit:hover { background: var(--tc-blue2); }
.tc-search-close {
    display: block; text-align: center; font-size: 12px;
    color: var(--tc-gray); margin-top: 12px; cursor: pointer;
    font-family: 'DM Sans', sans-serif;
}

/* ═══════════════════════════════════════════════════════════
   MOBILE OVERLAY
═══════════════════════════════════════════════════════════ */
.tc-overlay {
    position: fixed; inset: 0; z-index: 10003;
    background: rgba(13,30,60,.5);
    opacity: 0; visibility: hidden;
    transition: opacity .3s, visibility .3s;
}
.tc-overlay.tc-active { opacity: 1; visibility: visible; }

/* ═══════════════════════════════════════════════════════════
   MOBILE DRAWER
═══════════════════════════════════════════════════════════ */
.tc-drawer {
    position: fixed;
    top: 0; right: 0; bottom: 0;
    z-index: 10004;
    width: min(320px, 90vw);
    background: #fff;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateX(100%);
    transition: transform .35s cubic-bezier(.4,0,.2,1);
}
.tc-drawer.tc-open { transform: translateX(0); }

/* STICKY drawer header — stays at top while body scrolls */
.tc-drawer-head {
    position: relative;
    z-index: 2;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    background: #fff;
    border-bottom: 1px solid var(--tc-border);
    flex-shrink: 0;
}
.tc-drawer-head .tc-logo { margin-right: 0; }

.tc-drawer-close {
    width: 34px; height: 34px;
    background: var(--tc-light);
    border: 1.5px solid var(--tc-border);
    border-radius: 8px;
    display: grid; place-items: center;
    font-size: 15px; cursor: pointer;
    color: var(--tc-navy); flex-shrink: 0;
}

/* Scrollable body — fills remaining height between head and foot */
.tc-drawer-body {
    flex: 1 1 0;
    min-height: 0;
    overflow-y: scroll;
    -webkit-overflow-scrolling: touch;
    overscroll-behavior: contain;
    padding: 12px 14px;
}

ul.tc-mobile-menu { list-style: none; margin: 0; padding: 0; }

/* Standalone link (no children) */
.tc-mob-link {
    display: flex; align-items: center;
    padding: 12px 14px; border-radius: 10px;
    font-size: 14px; font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    color: var(--tc-navy); text-decoration: none;
    border: 1px solid var(--tc-border);
    margin-bottom: 7px;
    transition: background .15s, border-color .15s;
}
.tc-mob-link:hover { background: var(--tc-light); border-color: var(--tc-blue); color: var(--tc-blue); }

/* Accordion group */
.tc-mob-grp {
    border: 1px solid var(--tc-border);
    border-radius: 11px;
    margin-bottom: 7px;
    overflow: hidden;
}

/* Accordion toggle button */
.tc-mob-title {
    width: 100%;
    display: flex; align-items: center;
    justify-content: space-between;
    padding: 13px 14px;
    font-size: 14px; font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    color: var(--tc-navy);
    background: none; border: none;
    cursor: pointer; text-align: left; gap: 8px;
    transition: background .15s;
}
.tc-mob-title:hover { background: var(--tc-light); }
.tc-mob-title span { flex: 1; }

.tc-mob-arr {
    flex-shrink: 0;
    transition: transform .25s;
}
.tc-mob-grp.tc-mob-open > .tc-mob-title { border-bottom: 1px solid var(--tc-border); }
.tc-mob-grp.tc-mob-open .tc-mob-arr { transform: rotate(180deg); }

/* Accordion body */
.tc-mob-body {
    max-height: 0;
    overflow: hidden;
    transition: max-height .32s ease;
}
.tc-mob-grp.tc-mob-open .tc-mob-body { max-height: 1200px; padding: 6px 8px 8px; }

/* Sub-item links */
.tc-mob-sub {
    display: flex; align-items: center;
    padding: 10px 10px; border-radius: 8px;
    font-size: 13.5px; font-weight: 600;
    font-family: 'DM Sans', sans-serif;
    color: var(--tc-navy); text-decoration: none;
    transition: background .15s, color .15s;
}
.tc-mob-sub:hover { background: var(--tc-light); color: var(--tc-blue); }

/* Drawer footer — stays at bottom via flexbox */
.tc-drawer-foot {
    position: relative;
    background: #fff;
    padding: 14px;
    border-top: 1px solid var(--tc-border);
    display: flex; flex-direction: column; gap: 10px;
    flex-shrink: 0;
}
.tc-drawer-cta {
    display: flex; justify-content: center; align-items: center; gap: 7px;
    background: var(--tc-pink); color: #fff !important;
    font-size: 14px; font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    padding: 13px; border-radius: 10px;
    text-decoration: none !important;
    transition: box-shadow .15s;
}
.tc-drawer-cta:hover { box-shadow: 0 4px 18px rgba(232,62,90,.35); }

.tc-drawer-phone {
    display: flex; justify-content: center; align-items: center; gap: 7px;
    border: 1.5px solid var(--tc-border);
    color: var(--tc-navy); font-size: 14px; font-weight: 700;
    font-family: 'DM Sans', sans-serif;
    padding: 11px; border-radius: 10px; text-decoration: none;
    transition: border-color .15s;
}
.tc-drawer-phone:hover { border-color: var(--tc-blue); color: var(--tc-blue); }

/* ═══════════════════════════════════════════════════════════
   RESPONSIVE
═══════════════════════════════════════════════════════════ */
@media (max-width: 767px) {
    .tc-phone-link   { display: none !important; }
    .tc-cta-btn      { padding: 9px 14px; font-size: 12.5px; }
    .tc-header-inner { padding: 0 14px; }
    .tc-actions      { gap: 6px; }
}
@media (max-width: 480px) {
    .tc-cta-btn  { padding: 9px 12px; font-size: 12px; }
    .tc-logo-img { height: 30px; max-width: 130px; }
}

/* ═══════════════════════════════════════════════════════════
   MOBILE DRAWER — DEPTH 2 SUPPORT (section labels + sub-items)
═══════════════════════════════════════════════════════════ */

/* Section label (depth-1 item WITH children — non-clickable header) */
.tc-mob-sec-head {
    font-size: 10.5px;
    font-weight: 800;
    letter-spacing: 1.8px;
    text-transform: uppercase;
    color: var(--tc-blue);
    padding: 10px 10px 5px;
    margin-top: 4px;
}

/* First section head inside a group — no extra top margin */
.tc-mob-body .tc-mob-sec-head:first-child {
    margin-top: 0;
    padding-top: 6px;
}

/* The list of depth-2 items under a section */
ul.tc-mob-sec-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* Depth-2 link */
a.tc-mob-sub2 {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 9px 10px 9px 16px;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 500;
    font-family: 'DM Sans', sans-serif;
    color: #4b5563;
    text-decoration: none;
    transition: background .14s, color .14s;
    position: relative;
}

a.tc-mob-sub2::before {
    content: '';
    position: absolute;
    left: 6px;
    top: 50%;
    transform: translateY(-50%);
    width: 3px;
    height: 3px;
    border-radius: 50%;
    background: var(--tc-border);
    flex-shrink: 0;
}

a.tc-mob-sub2:hover,
a.tc-mob-sub2--active {
    background: var(--tc-light);
    color: var(--tc-blue);
}

a.tc-mob-sub2--active::before {
    background: var(--tc-blue);
}

/* Separator line between sections inside same accordion */
ul.tc-mob-sec-list + .tc-mob-sec-head {
    border-top: 1px solid var(--tc-border);
    margin-top: 6px;
    padding-top: 12px;
}
