:root {
    --bg-gradient: linear-gradient(135deg, #f8fafc 0%, #f1f5f9 100%);
    --glass-bg: #ffffff;
    --glass-border: #94a3b8;
    --text-main: #0f172a;
    --text-muted: #475569;
    --accent-grad: linear-gradient(135deg, #6366f1 0%, #a855f7 100%);
    --accent-grad-hover: linear-gradient(135deg, #4f46e5 0%, #9333ea 100%);
    --input-bg: #f1f5f9;
}

* {
    box-sizing: border-box;
}

html,
body {
    height: 100%;
    margin: 0;
    font-family: 'Outfit', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
    font-size-adjust: 0.52;
    background: var(--bg-gradient);
    color: var(--text-main);
    -webkit-font-smoothing: antialiased;
}

.wrapper {
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    overflow-x: hidden;
    position: relative;
}

header {
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 12px 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border-bottom: 1px solid rgba(148, 163, 184, 0.2);
    transition: all 0.3s ease;
    gap: 16px;
}

@media (max-width: 600px) {
    header {
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }
}

header.scrolled {
    padding: 12px 32px;
    background: rgba(255, 255, 255, 0.95);
    box-shadow: 0 4px 20px -5px rgba(0, 0, 0, 0.07);
}

/* Logo */
.logo-block {
    flex-shrink: 0;
}

.logo-link {
    text-decoration: none;
    display: flex;
    flex-direction: column;
    line-height: 1.1;
    gap: 2px;
}

.logo-name {
    font-size: 22px;
    font-weight: 800;
    letter-spacing: -0.8px;
    background: var(--accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: block;
}

.logo-sub {
    font-size: 9px;
    font-weight: 500;
    letter-spacing: 0.6px;
    text-transform: uppercase;
    color: var(--text-muted);
    -webkit-text-fill-color: var(--text-muted);
    display: block;
    opacity: 0.75;
}

nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 4px;
    flex-wrap: nowrap;
    /* Prevent wrapping on desktop */
}

nav ul li a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    padding: 8px 14px;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    position: relative;
    display: inline-block;
}

nav ul li a:hover {
    color: #7c3aed;
    background: #f5f3ff;
}

nav ul li a.active {
    color: white;
    background: var(--accent-grad);
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.2);
}

/* ── Nav Dropdown ── */
.has-dropdown {
    position: relative;
}

/* Invisible bridge keeps hover active when moving cursor into panel */
.has-dropdown::after {
    content: '';
    position: absolute;
    top: 100%;
    left: -20px;
    right: -20px;
    height: 16px;
}

.nav-dropdown-trigger {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 14px;
    padding: 8px 14px;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    white-space: nowrap;
    cursor: pointer;
    background: none;
    border: none;
    font-family: 'Outfit', sans-serif;
    line-height: inherit;
}

.nav-dropdown-trigger:hover,
.has-dropdown:hover .nav-dropdown-trigger {
    color: #7c3aed;
    background: #f5f3ff;
}

.nav-dropdown-trigger.active {
    color: white;
    background: var(--accent-grad);
    box-shadow: 0 4px 12px rgba(124, 58, 237, 0.2);
}

.nav-dropdown-trigger.active svg {
    color: rgba(255, 255, 255, 0.8);
}

.nav-dropdown-trigger svg {
    color: #94a3b8;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

.has-dropdown:hover .nav-dropdown-trigger svg,
.has-dropdown:focus-within .nav-dropdown-trigger svg {
    transform: rotate(180deg);
}

.nav-dropdown {
    position: absolute;
    top: calc(100% + 14px);
    right: 0;
    left: auto;
    background: #ffffff;
    border: 1px solid rgba(99, 102, 241, 0.15);
    border-radius: 18px;
    box-shadow: 0 8px 32px -4px rgba(0, 0, 0, 0.12),
                0 24px 64px -12px rgba(99, 102, 241, 0.15),
                0 0 0 1px rgba(255,255,255,0.8) inset;
    padding: 12px;
    width: 520px;
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
    transition: opacity 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.2s cubic-bezier(0.4, 0, 0.2, 1),
                visibility 0.2s;
    transform: translateY(6px);
    z-index: 1200;
}

.has-dropdown:hover .nav-dropdown,
.has-dropdown:focus-within .nav-dropdown {
    opacity: 1;
    visibility: visible;
    pointer-events: auto;
    transform: translateY(0);
}

.nav-dropdown-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 4px 6px 10px;
    border-bottom: 1px solid #f1f5f9;
    margin-bottom: 10px;
}

.nav-dropdown-header span {
    font-size: 10px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
    color: #94a3b8;
}

.nav-dropdown-header a {
    font-size: 12px;
    font-weight: 600;
    color: #7c3aed;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: gap 0.2s;
    padding: 0;
    background: none;
    border-radius: 0;
    box-shadow: none;
}

.nav-dropdown-header a:hover {
    gap: 7px;
    background: none;
    color: #6d28d9;
}

.nav-dropdown-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 3px;
}

.nav-dropdown-item {
    display: flex;
    align-items: center;
    gap: 9px;
    padding: 9px 10px;
    border-radius: 10px;
    text-decoration: none;
    color: var(--text-muted);
    font-size: 13px;
    font-weight: 500;
    transition: all 0.18s cubic-bezier(0.4, 0, 0.2, 1);
    line-height: 1.3;
    white-space: nowrap;
}

.nav-dropdown-item:hover {
    background: #f5f3ff;
    color: #7c3aed;
    transform: none;
    box-shadow: none;
}

.nav-dropdown-item.active {
    background: linear-gradient(135deg, #ede9fe, #f5f3ff);
    color: #7c3aed;
    font-weight: 600;
}

.nav-dropdown-item svg {
    color: #a855f7;
    flex-shrink: 0;
    opacity: 0.8;
}

.nav-dropdown-item:hover svg,
.nav-dropdown-item.active svg {
    opacity: 1;
}

/* ── Mobile Drawer Sub-menu ── */
.drawer-nav .has-sub > .drawer-sub-trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    padding: 14px 24px;
    color: var(--text-muted);
    font-weight: 500;
    font-size: 16px;
    background: none;
    border: none;
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    text-align: left;
    transition: all 0.2s;
}

.drawer-nav .has-sub > .drawer-sub-trigger:hover,
.drawer-nav .has-sub.open > .drawer-sub-trigger {
    color: var(--text-main);
    background: #f8fafc;
    padding-left: 30px;
}

.drawer-nav .has-sub.open > .drawer-sub-trigger {
    color: #7c3aed;
    font-weight: 600;
}

.drawer-sub-trigger .sub-icon {
    color: #a855f7;
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    flex-shrink: 0;
}

.drawer-nav .has-sub.open .sub-icon {
    transform: rotate(180deg);
}

.drawer-sub-menu {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1);
    background: #f8fafc;
    border-top: 1px solid #f1f5f9;
    border-bottom: 1px solid #f1f5f9;
}

.drawer-nav .has-sub.open .drawer-sub-menu {
    max-height: 52vh;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.drawer-sub-menu a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 11px 24px 11px 32px;
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s;
}

.drawer-sub-menu a:hover,
.drawer-sub-menu a.active {
    color: #7c3aed;
    background: #f0ebff;
    padding-left: 38px;
}

.drawer-sub-menu a svg {
    color: #a855f7;
    flex-shrink: 0;
}

main {
    position: relative;
    z-index: 10;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 60px 20px;
}

.menu-trigger {
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: background 0.2s;
    flex: initial;
}

.menu-trigger:hover {
    background: rgba(0, 0, 0, 0.05);
}

/* Side Drawer */
.side-drawer {
    position: fixed;
    top: 0;
    right: -300px;
    width: 300px;
    height: 100%;
    background: #ffffff;
    z-index: 1100;
    box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
    transition: right 0.4s cubic-bezier(0.16, 1, 0.3, 1);
    display: flex;
    flex-direction: column;
}

.side-drawer.open {
    right: 0;
}

.drawer-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(4px);
    z-index: 1099;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.drawer-overlay.active {
    opacity: 1;
    visibility: visible;
}

.drawer-header {
    padding: 24px;
    border-bottom: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.drawer-close {
    background: #f1f5f9;
    border: none;
    color: var(--text-muted);
    padding: 8px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex: initial;
}

.drawer-nav {
    flex: 1;
    overflow-y: auto;
    padding: 20px 0;
}

.drawer-nav ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
}

.drawer-nav ul li a {
    display: block;
    padding: 14px 24px;
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 16px;
    transition: all 0.2s;
}

.drawer-nav ul li a:hover,
.drawer-nav ul li a.active {
    color: var(--text-main);
    background: #f8fafc;
    padding-left: 30px;
}

.drawer-nav ul li a.active {
    color: #7c3aed;
    font-weight: 600;
}

@media (max-width: 1024px) {
    .desktop-nav {
        display: none;
    }

    .menu-trigger {
        display: flex;
    }
}

@media (min-width: 1025px) and (max-width: 1280px) {
    header {
        padding: 10px 24px;
    }

    header.scrolled {
        padding: 8px 24px;
    }

    nav ul li a {
        padding: 8px 10px;
        font-size: 13px;
    }

    .nav-dropdown-trigger {
        padding: 8px 10px;
        font-size: 13px;
    }

    .nav-dropdown {
        width: 460px;
    }
}

.container {
    width: 100%;
    max-width: 850px;
    background: var(--glass-bg);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--glass-border);
    border-radius: 24px;
    padding: 30px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.08), inset 0 1px 0 rgba(255, 255, 255, 0.8);
    animation: slideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(40px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.container h2 {
    text-align: center;
    margin: 0 0 24px 0;
    font-size: 26px;
    font-weight: 600;
    letter-spacing: -0.5px;
    color: var(--text-main);
}

.form-group {
    margin-bottom: 16px;
}

label {
    font-weight: 500;
    display: flex;
    margin-bottom: 6px;
    color: var(--text-muted);
    font-size: 14px;
    letter-spacing: 0.5px;
    text-transform: uppercase;
}

input[type="text"],
input[type="number"],
input[type="date"],
input[type="datetime-local"],
select {
    width: 100%;
    padding: 10px 14px;
    background: var(--input-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    font-size: 16px;
    color: var(--text-main);
    font-family: 'Outfit', sans-serif;
    transition: all 0.3s;
    box-sizing: border-box;
}

select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml;utf8,<svg fill='%23475569' height='24' viewBox='0 0 24 24' width='24' xmlns='http://www.w3.org/2000/svg'><path d='M7 10l5 5 5-5z'/><path d='M0 0h24v24H0z' fill='none'/></svg>");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 40px;
}

input[type="text"]::placeholder,
input[type="number"]::placeholder {
    color: #64748b;
}

input:focus,
select:focus {
    border-color: #a855f7;
    box-shadow: 0 0 0 4px rgba(168, 85, 247, 0.15);
    outline: none;
}

select option {
    background: #ffffff;
    color: #0f172a;
}

::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f5f9;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb {
    background: #cbd5e1;
    border-radius: 4px;
    border: 2px solid #f1f5f9;
}

::-webkit-scrollbar-thumb:hover {
    background: #a855f7;
}

.row {
    display: flex;
    gap: 12px;
}

.row>* {
    flex: 1;
}

.buttons {
    display: flex;
    gap: 16px;
    margin-top: 24px;
}

button {
    padding: 12px;
    font-size: 16px;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Outfit', sans-serif;
}

.buttons button {
    flex: 1;
}

.clear-btn {
    background: transparent;
    color: var(--text-main);
    border: 1px solid var(--glass-border);
}

.clear-btn:hover {
    background: #e2e8f0;
    transform: translateY(-2px);
}

.calculate-btn {
    background: var(--accent-grad);
    color: white;
    box-shadow: 0 4px 15px -3px rgba(168, 85, 247, 0.4);
}

.calculate-btn:hover {
    background: var(--accent-grad-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 25px -5px rgba(168, 85, 247, 0.6);
}

button:active {
    transform: translateY(0);
}

#result,
#ageResult,
#tzResult,
#dateDiffResult,
#overtimeResult,
#workingDaysResult,
#h2sResult,
#timeDurationResult {
    margin-top: 0;
    height: 100%;
    display: none;
    align-items: center;
    justify-content: center;
    flex-direction: column;
    font-size: 24px;
    line-height: 1.4;
    font-weight: 500;
    text-align: center;
    color: var(--text-main);
    min-height: 27px;
    background: transparent;
    padding: 12px;
    border-radius: 12px;
    border: none;
    opacity: 0;
    animation: fadeInResult 0.5s forwards;
}

#result.show,
#ageResult.show,
#tzResult.show,
#dateDiffResult.show,
#overtimeResult.show,
#workingDaysResult.show,
#h2sResult.show,
#timeDurationResult.show {
    display: flex;
}

@keyframes fadeInResult {
    from {
        opacity: 0;
        transform: translateY(5px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* ─────────────── Scroll To Top Button ─────────────── */
.scroll-top-btn {
    position: fixed;
    bottom: 28px;
    right: 28px;
    z-index: 999;
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: var(--accent-grad);
    color: white;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 20px -4px rgba(124, 58, 237, 0.5);
    opacity: 0;
    transform: translateY(12px);
    pointer-events: none;
    transition: opacity 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                transform 0.3s cubic-bezier(0.4, 0, 0.2, 1),
                box-shadow 0.2s;
    flex: initial;
}

.scroll-top-btn.visible {
    opacity: 1;
    transform: translateY(0);
    pointer-events: auto;
}

.scroll-top-btn:hover {
    box-shadow: 0 8px 28px -4px rgba(124, 58, 237, 0.65);
    transform: translateY(-3px);
}

.scroll-top-btn:active {
    transform: translateY(0);
}

@media (max-width: 480px) {
    .scroll-top-btn {
        bottom: 18px;
        right: 18px;
        width: 40px;
        height: 40px;
        border-radius: 12px;
    }
}

footer {
    margin-top: 80px;
    position: relative;
    z-index: 10;
    padding: 80px 48px 40px 48px;
    background: #ffffff;
    border-top: 1px solid rgba(148, 163, 184, 0.2);
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 48px;
}

.footer-brand {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.footer-brand p {
    color: var(--text-muted);
    font-size: 15px;
    line-height: 1.6;
    max-width: 300px;
    margin: 0;
}

.footer-column h4 {
    font-size: 16px;
    font-weight: 700;
    margin: 0 0 24px 0;
    color: var(--text-main);
}

.footer-column ul {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.footer-column ul li a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    font-weight: 500;
    transition: all 0.2s ease;
}

.footer-column ul li a:hover {
    color: #7c3aed;
    padding-left: 4px;
}

.footer-bottom {
    max-width: 1200px;
    margin: 60px auto 0 auto;
    padding-top: 32px;
    border-top: 1px solid #f1f5f9;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
}

.footer-bottom p {
    margin: 0;
    font-size: 14px;
    color: var(--text-muted);
}

.social-link {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    background: #f1f5f9;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: #7c3aed;
    color: white;
    transform: translateY(-3px);
}

.layout-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
}

.form-section {
    display: flex;
    flex-direction: column;
}

.result-section {
    display: flex;
    flex-direction: column;
    justify-content: center;
    background: #f8fafc;
    border-radius: 16px;
    padding: 30px;
    border: none;
    min-height: 250px;
    text-align: center;
}

.result-placeholder {
    transition: opacity 0.3s;
    color: #94a3b8;
    font-size: 16px;
    font-weight: 500;
}

@media (max-width: 991px) {
    .footer-container {
        grid-template-columns: 1fr 1fr;
        gap: 40px;
    }

    footer {
        padding: 60px 24px 40px 24px;
    }
}

@media (max-width: 560px) {
    .footer-container {
        grid-template-columns: 1fr;
        gap: 32px;
    }

    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
}

@media (max-width: 768px) {
    header {
        padding: 10px 16px;
        flex-direction: row;
        justify-content: space-between;
        gap: 10px;
    }

    .logo-block {
        text-align: left;
    }

    .logo-link {
        align-items: flex-start;
    }

    nav ul {
        justify-content: center;
        gap: 10px 6px;
    }

    nav ul li a {
        padding: 8px 14px;
        font-size: 14px;
    }

    .layout-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .result-section {
        min-height: 150px;
        padding: 20px;
    }

    .container h2 {
        font-size: 22px;
    }

    #result,
    #ageResult,
    #tzResult,
    #dateDiffResult,
    #overtimeResult,
    #workingDaysResult,
    #h2sResult,
    #timeDurationResult {
        font-size: 20px;
    }
}

@media (max-width: 480px) {
    .row {
        flex-direction: column;
        gap: 12px;
    }

    .buttons {
        flex-direction: column;
        gap: 12px;
    }

    .container {
        padding: 24px 16px;
        border-radius: 16px;
    }

    header {
        padding: 10px 14px;
    }

    .logo-name {
        font-size: 18px;
    }

    nav ul li a {
        padding: 6px 10px;
        font-size: 12px;
    }

    .footer-separator {
        display: none;
    }

    .footer-links {
        gap: 12px 16px;
        padding: 0 10px;
    }
}

.result-section:has(.show) .result-placeholder {
    display: none;
}

/* ───────────── Informational Content Section ───────────── */
.info-section {
    width: 100%;
    max-width: 850px;
    margin: 32px auto 48px auto;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.info-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 28px 32px;
    box-shadow: 0 4px 24px -8px rgba(0, 0, 0, 0.06);
    animation: slideUp 0.9s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.info-card h3 {
    margin: 0 0 14px 0;
    font-size: 19px;
    font-weight: 700;
    letter-spacing: -0.3px;
    background: var(--accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: inline-block;
}

.info-card p {
    margin: 0 0 10px 0;
    font-size: 15px;
    line-height: 1.75;
    color: var(--text-muted);
    text-align: justify;
}

.info-card p:last-child {
    margin-bottom: 0;
}

.info-card ul,
.info-card ol {
    margin: 8px 0 0 0;
    padding-left: 22px;
    color: var(--text-muted);
    font-size: 15px;
    line-height: 1.8;
}

.info-card ul li,
.info-card ol li {
    margin-bottom: 6px;
}

/* Example box */
.example-box {
    background: linear-gradient(135deg, #f5f3ff 0%, #faf5ff 100%);
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: 14px;
    padding: 18px 22px;
    margin-top: 12px;
    font-size: 15px;
    color: var(--text-main);
    line-height: 1.75;
}

.example-box strong {
    color: #7c3aed;
}

/* FAQ accordion */
.faq-item {
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    margin-bottom: 10px;
    overflow: hidden;
    transition: box-shadow 0.2s;
}

.faq-item:last-child {
    margin-bottom: 0;
}

.faq-item:hover {
    box-shadow: 0 4px 16px -4px rgba(168, 85, 247, 0.15);
}

.faq-question {
    width: 100%;
    background: none;
    border: none;
    text-align: left;
    padding: 16px 20px;
    font-size: 15px;
    font-weight: 600;
    color: var(--text-main);
    font-family: 'Outfit', sans-serif;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    transition: background 0.2s;
    flex: initial;
}

.faq-question:hover {
    background: #f8fafc;
    transform: none;
    box-shadow: none;
}

.faq-question .faq-icon {
    font-size: 20px;
    color: #a855f7;
    flex-shrink: 0;
    transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    line-height: 1;
}

.faq-item.open .faq-icon {
    transform: rotate(45deg);
}

.faq-answer {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s cubic-bezier(0.4, 0, 0.2, 1), padding 0.35s;
    padding: 0 20px;
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.75;
}

.faq-item.open .faq-answer {
    max-height: 300px;
    padding: 0 20px 16px 20px;
}

@media (max-width: 600px) {
    .info-card {
        padding: 22px 20px;
    }
}

/* ───────────── Home / Tools Page ───────────── */
main.main-home {
    padding: 0;
    align-items: stretch;
}

/* ───────────── Content Pages (About / Contact / Privacy / Terms / Disclaimer) ───────────── */
main.main-content {
    padding: 0;
    align-items: stretch;
}

/* Hero */
.page-hero {
    text-align: center;
    padding: 64px 24px 48px;
    max-width: 720px;
    margin: 0 auto;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: linear-gradient(135deg, #f5f3ff, #faf5ff);
    border: 1px solid rgba(168, 85, 247, 0.25);
    border-radius: 999px;
    padding: 6px 18px;
    font-size: 13px;
    font-weight: 600;
    color: #7c3aed;
    margin-bottom: 24px;
    letter-spacing: 0.3px;
}

.page-hero h1 {
    font-size: 52px;
    font-weight: 800;
    letter-spacing: -2px;
    line-height: 1.08;
    margin: 0 0 18px 0;
    color: var(--text-main);
}

.page-hero h1 .accent {
    background: var(--accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.page-hero > p {
    font-size: 18px;
    color: var(--text-muted);
    line-height: 1.7;
    margin: 0 0 36px 0;
}

.hero-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    margin-bottom: 48px;
}

.hero-btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: var(--accent-grad);
    color: white;
    padding: 14px 28px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 4px 18px -4px rgba(124, 58, 237, 0.45);
}

.hero-btn-primary:hover {
    background: var(--accent-grad-hover);
    transform: translateY(-2px);
    box-shadow: 0 8px 28px -4px rgba(124, 58, 237, 0.6);
}

.hero-btn-secondary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: white;
    color: var(--text-main);
    padding: 14px 28px;
    border-radius: 14px;
    font-size: 15px;
    font-weight: 600;
    text-decoration: none;
    border: 1px solid var(--glass-border);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.hero-btn-secondary:hover {
    background: #f5f3ff;
    border-color: rgba(168, 85, 247, 0.3);
    color: #7c3aed;
    transform: translateY(-2px);
}

.hero-stats {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    border: 1px solid var(--glass-border);
    border-radius: 18px;
    background: white;
    overflow: hidden;
    box-shadow: 0 4px 24px -8px rgba(0, 0, 0, 0.06);
    max-width: 480px;
    margin: 0 auto;
}

.hero-stat {
    flex: 1;
    padding: 20px 16px;
    text-align: center;
    position: relative;
}

.hero-stat + .hero-stat::before {
    content: '';
    position: absolute;
    left: 0;
    top: 20%;
    height: 60%;
    width: 1px;
    background: var(--glass-border);
}

.hero-stat .stat-number {
    font-size: 26px;
    font-weight: 800;
    background: var(--accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: block;
    line-height: 1;
    margin-bottom: 4px;
}

.hero-stat .stat-label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
    letter-spacing: 0.3px;
}

/* Tools Grid Section */
.tools-section {
    width: 100%;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px 72px;
}

.tools-section-header {
    display: flex;
    align-items: baseline;
    gap: 12px;
    margin-bottom: 24px;
}

.tools-section-header h2 {
    font-size: 22px;
    font-weight: 700;
    margin: 0;
    color: var(--text-main);
    letter-spacing: -0.4px;
}

.tools-section-header .tools-count {
    font-size: 13px;
    font-weight: 600;
    color: #a855f7;
    background: #f5f3ff;
    border: 1px solid rgba(168, 85, 247, 0.2);
    border-radius: 999px;
    padding: 2px 10px;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.tool-card {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 20px;
    padding: 24px;
    text-decoration: none;
    display: flex;
    flex-direction: column;
    gap: 16px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 2px 12px -4px rgba(0, 0, 0, 0.05);
    position: relative;
    overflow: hidden;
}

.tool-card::after {
    content: '';
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, rgba(99, 102, 241, 0.03), rgba(168, 85, 247, 0.05));
    opacity: 0;
    transition: opacity 0.3s;
    pointer-events: none;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 44px -10px rgba(124, 58, 237, 0.18);
    border-color: rgba(168, 85, 247, 0.35);
}

.tool-card:hover::after {
    opacity: 1;
}

.tool-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
}

.tool-card-icon {
    width: 48px;
    height: 48px;
    border-radius: 14px;
    background: linear-gradient(135deg, #f5f3ff, #faf5ff);
    border: 1px solid rgba(168, 85, 247, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #7c3aed;
    flex-shrink: 0;
}

.tool-card-arrow {
    width: 32px;
    height: 32px;
    border-radius: 10px;
    background: linear-gradient(135deg, #f5f3ff, #faf5ff);
    border: 1px solid rgba(168, 85, 247, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a855f7;
    flex-shrink: 0;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.tool-card:hover .tool-card-arrow {
    background: var(--accent-grad);
    border-color: transparent;
    color: white;
    transform: translate(2px, -2px);
}

.tool-card h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0 0 6px 0;
    letter-spacing: -0.2px;
}

.tool-card p {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.65;
    margin: 0;
}

/* Page header for /tools */
.page-header {
    text-align: center;
    padding: 56px 24px 40px;
    max-width: 600px;
    margin: 0 auto;
}

.page-header h1 {
    font-size: 38px;
    font-weight: 800;
    letter-spacing: -1.2px;
    margin: 0 0 12px 0;
    color: var(--text-main);
}

.page-header h1 .accent {
    background: var(--accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.page-header p {
    font-size: 16px;
    color: var(--text-muted);
    line-height: 1.7;
    margin: 0;
}

/* Responsive */
@media (max-width: 960px) {
    .tools-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .page-hero h1 {
        font-size: 40px;
    }
}

@media (max-width: 600px) {
    .tools-grid {
        grid-template-columns: 1fr;
    }

    .page-hero {
        padding: 40px 20px 36px;
    }

    .page-hero h1 {
        font-size: 32px;
        letter-spacing: -1px;
    }

    .page-hero > p {
        font-size: 16px;
    }

    .hero-btn-primary,
    .hero-btn-secondary {
        width: 100%;
        justify-content: center;
    }

    .page-header h1 {
        font-size: 28px;
    }

    .tools-section {
        padding: 0 16px 56px;
    }
}

/* ───────────── FAQ Page Tool Sections ───────────── */
.faq-tool-section {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.faq-tool-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 4px 12px;
}

.faq-tool-icon {
    width: 34px;
    height: 34px;
    border-radius: 10px;
    background: linear-gradient(135deg, #f5f3ff, #faf5ff);
    border: 1px solid rgba(168, 85, 247, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #7c3aed;
    flex-shrink: 0;
}

.faq-tool-header h2 {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0;
    letter-spacing: -0.2px;
    flex: 1;
}

.faq-tool-link {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 600;
    color: #a855f7;
    text-decoration: none;
    padding: 5px 12px;
    border-radius: 999px;
    background: #f5f3ff;
    border: 1px solid rgba(168, 85, 247, 0.2);
    white-space: nowrap;
    transition: all 0.2s;
    flex-shrink: 0;
}

.faq-tool-link:hover {
    background: var(--accent-grad);
    color: white;
    border-color: transparent;
}

/* FAQ CTA banner on individual tool pages */
.faq-cta-card {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 16px 24px !important;
    color: var(--text-muted);
    font-size: 14px;
    font-weight: 500;
}

.faq-cta-card svg {
    color: #a855f7;
    flex-shrink: 0;
}

.faq-cta-card span {
    flex: 1;
}

.faq-cta-card a {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 13px;
    font-weight: 600;
    color: #7c3aed;
    text-decoration: none;
    padding: 5px 14px;
    border-radius: 999px;
    background: #f5f3ff;
    border: 1px solid rgba(168, 85, 247, 0.2);
    white-space: nowrap;
    transition: all 0.2s;
    flex-shrink: 0;
}

.faq-cta-card a:hover {
    background: var(--accent-grad);
    color: white;
    border-color: transparent;
}

@media (max-width: 480px) {
    .faq-cta-card {
        flex-wrap: wrap;
    }
}

/* ───────────── Content Pages (About / Contact / Privacy / Terms / Disclaimer) ───────────── */

.page-banner {
    width: 100%;
    background: linear-gradient(135deg, #f5f3ff 0%, #faf5ff 60%, #f0f9ff 100%);
    border-bottom: 1px solid rgba(168, 85, 247, 0.12);
    padding: 52px 24px 48px;
    text-align: center;
}

.page-banner-inner {
    max-width: 680px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 14px;
}

.page-banner-icon {
    width: 60px;
    height: 60px;
    border-radius: 18px;
    background: var(--accent-grad);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: 0 8px 24px -4px rgba(124, 58, 237, 0.4);
    margin-bottom: 4px;
}

.page-banner h1 {
    font-size: 36px;
    font-weight: 800;
    letter-spacing: -1px;
    color: var(--text-main);
    margin: 0;
}

.page-banner p {
    font-size: 16px;
    color: var(--text-muted);
    line-height: 1.7;
    margin: 0;
    max-width: 520px;
}

/* Page content wrapper for content pages */
.page-content {
    width: 100%;
    max-width: 860px;
    margin: 0 auto;
    padding: 40px 24px 72px;
}

/* ───────────── Blog (Back link + readability) ───────────── */
.blog-back {
    margin: 0 0 16px 0;
}

.blog-back a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    border-radius: 12px;
    border: 1px solid rgba(148, 163, 184, 0.35);
    background: rgba(255, 255, 255, 0.7);
    color: var(--text-main);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    transition: background 0.2s ease, border-color 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.blog-back a:hover {
    background: #f5f3ff;
    border-color: rgba(168, 85, 247, 0.25);
    color: #7c3aed;
    transform: translateY(-1px);
}

.blog-back--bottom {
    margin: 14px 0 0 0;
}

.blog-post .info-card p {
    text-justify: inter-word;
}

@media (max-width: 640px) {
    .blog-post .info-card p {
        text-align: left;
        text-justify: auto;
    }
}

/* Card icon badge */
.card-icon-badge {
    width: 44px;
    height: 44px;
    border-radius: 14px;
    background: linear-gradient(135deg, #f5f3ff, #faf5ff);
    border: 1px solid rgba(168, 85, 247, 0.18);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #7c3aed;
    flex-shrink: 0;
    margin-bottom: 16px;
}

.info-card-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 14px;
}

.info-card-header .card-icon-badge {
    margin-bottom: 0;
}

.info-card-header h3 {
    margin: 0 !important;
}

/* Section number badge */
.section-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: var(--accent-grad);
    color: white;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
}

/* About page stats */
.about-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-top: 8px;
}

.about-stat {
    background: linear-gradient(135deg, #f5f3ff, #faf5ff);
    border: 1px solid rgba(168, 85, 247, 0.15);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
}

.about-stat .stat-num {
    font-size: 28px;
    font-weight: 800;
    background: var(--accent-grad);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    display: block;
    line-height: 1;
    margin-bottom: 6px;
}

.about-stat .stat-lbl {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
}

/* Feature list with icons */
.feature-list {
    list-style: none;
    padding: 0;
    margin: 12px 0 0 0;
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.feature-list li {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    font-size: 15px;
    color: var(--text-muted);
    line-height: 1.6;
    margin-bottom: 0 !important;
}

.feature-list li .fl-icon {
    width: 22px;
    height: 22px;
    border-radius: 6px;
    background: linear-gradient(135deg, #ede9fe, #f5f3ff);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #7c3aed;
    flex-shrink: 0;
    margin-top: 1px;
}

/* Contact email box */
.contact-email-box {
    background: linear-gradient(135deg, #f5f3ff 0%, #faf5ff 100%);
    border: 1.5px solid rgba(168, 85, 247, 0.25);
    border-radius: 16px;
    padding: 20px 24px;
    margin-top: 14px;
    display: flex;
    align-items: center;
    gap: 14px;
}

.contact-email-box .email-icon {
    width: 40px;
    height: 40px;
    border-radius: 12px;
    background: var(--accent-grad);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    flex-shrink: 0;
}

.contact-email-box a {
    color: #7c3aed;
    text-decoration: none;
    font-weight: 700;
    font-size: 18px;
    letter-spacing: -0.2px;
    transition: color 0.2s;
}

.contact-email-box a:hover {
    color: #5b21b6;
}

.contact-email-box .email-label {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 500;
    display: block;
    margin-bottom: 2px;
    letter-spacing: 0.3px;
    text-transform: uppercase;
}

/* Response time badge */
.response-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f0fdf4;
    border: 1px solid #bbf7d0;
    border-radius: 999px;
    padding: 5px 14px;
    font-size: 13px;
    font-weight: 600;
    color: #16a34a;
    margin-top: 12px;
}

/* Warning box for disclaimer */
.warning-box {
    background: linear-gradient(135deg, #fff7ed, #fffbeb);
    border: 1.5px solid rgba(251, 146, 60, 0.35);
    border-radius: 14px;
    padding: 16px 20px;
    margin-top: 14px;
    display: flex;
    gap: 12px;
    align-items: flex-start;
    font-size: 14px;
    color: #92400e;
    line-height: 1.65;
}

.warning-box .warn-icon {
    width: 24px;
    height: 24px;
    border-radius: 8px;
    background: rgba(251, 146, 60, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #f97316;
    flex-shrink: 0;
    margin-top: 1px;
}

.warning-box strong {
    color: #c2410c;
}

/* Policy section divider */
.policy-grid {
    display: flex;
    flex-direction: column;
    gap: 0;
}

.policy-section {
    display: grid;
    grid-template-columns: 32px 1fr;
    gap: 0 16px;
    padding: 22px 0;
    border-bottom: 1px solid #f1f5f9;
    animation: slideUp 0.7s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.policy-section:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.policy-section:first-child {
    padding-top: 0;
}

.policy-num {
    width: 28px;
    height: 28px;
    border-radius: 8px;
    background: var(--accent-grad);
    color: white;
    font-size: 12px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    margin-top: 2px;
}

.policy-body h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--text-main);
    margin: 0 0 8px 0;
    letter-spacing: -0.2px;
}

.policy-body p {
    font-size: 14px;
    line-height: 1.75;
    color: var(--text-muted);
    margin: 0 0 8px 0;
}

.policy-body p:last-child,
.policy-body ul:last-child {
    margin-bottom: 0;
}

.policy-body ul {
    margin: 8px 0 0 0;
    padding-left: 18px;
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.8;
}

.policy-body ul li {
    margin-bottom: 4px;
}

.policy-body a {
    color: #7c3aed;
    text-decoration: none;
    font-weight: 500;
}

.policy-body a:hover {
    text-decoration: underline;
}

@media (max-width: 600px) {
    .page-banner {
        padding: 36px 20px 32px;
    }

    .page-banner h1 {
        font-size: 28px;
    }

    .about-stats {
        grid-template-columns: repeat(3, 1fr);
        gap: 10px;
    }

    .about-stat .stat-num {
        font-size: 22px;
    }

    .contact-email-box {
        flex-direction: column;
        gap: 10px;
    }

    .contact-email-box a {
        font-size: 15px;
    }

    .page-content {
        padding: 28px 16px 56px;
    }
}