/* ═══════════════════════════════════════════
   AMBIENT GLOW
   ═══════════════════════════════════════════ */
.ambient {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: 600px;
    background: var(--glow);
    pointer-events: none;
    z-index: 0;
}

/* ═══════════════════════════════════════════
   TOPBAR
   ═══════════════════════════════════════════ */
.topbar {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 100;
    height: 72px;
    border-bottom: 1px solid var(--border-subtle);
}

.topbar::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    transition: background var(--dur) var(--ease);
}

[data-theme="dark"] .topbar::before {
    background: rgba(14, 14, 16, 0.85);
}

[data-theme="light"] .topbar::before {
    background: rgba(248, 248, 248, 0.85);
}

.topbar-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.topbar-brand {
    display: flex;
    align-items: center;
    height: 100%;
    text-decoration: none;
    position: relative;
    width: 220px;
}

.brand-logo {
    max-height: 120px;
    width: auto;
    position: absolute;
    left: -16px;
    top: 50%;
    transform: translateY(-50%);
    transition: opacity 300ms var(--ease);
}

html[data-theme="light"] .logo-dark {
    opacity: 0;
    pointer-events: none;
}

html[data-theme="light"] .logo-light {
    opacity: 1;
    pointer-events: auto;
}

html[data-theme="dark"] .logo-light {
    opacity: 0;
    pointer-events: none;
}

html[data-theme="dark"] .logo-dark {
    opacity: 1;
    pointer-events: auto;
}

.topbar-actions {
    display: flex;
    align-items: center;
    gap: 4px;
}

.topbar-nav {
    display: flex;
    gap: 16px;
    margin-left: auto;
    margin-right: 16px;
    height: 100%;
    align-items: center;
}

.topbar-nav a {
    color: var(--text-2);
    text-decoration: none;
    font-size: 0.9375rem;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 99px;
    transition: all 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

.topbar-nav a:hover {
    color: var(--text-1);
    background: var(--surface-hover);
    transform: translateY(-1px);
}

.topbar-nav a:active {
    transform: scale(0.96);
}

/* ═══════════════════════════════════════════
   LAYOUT
   ═══════════════════════════════════════════ */
.container {
    position: relative;
    z-index: 1;
    max-width: 1100px;
    margin: 0 auto;
    padding-top: 0;
    padding-inline: clamp(20px, 5vw, 32px);
    padding-bottom: clamp(64px, 10vw, 120px);
}

.calc-layout {
    display: grid;
    grid-template-columns: minmax(0, 1.3fr) minmax(0, 1fr);
    gap: clamp(24px, 4vw, 48px);
    align-items: start;
}

.calc-left {
    display: flex;
    flex-direction: column;
    gap: var(--space-card);
    min-width: 0;
}

.calc-left>.card {
    display: flex;
    flex-direction: column;
    flex: 1;
}

.calc-left>.card>.btn-reset-outline {
    margin-top: auto;
}

.calc-right {
    display: flex;
    flex-direction: column;
    gap: var(--space-card);
    position: sticky;
    top: 80px;
    align-self: flex-start;
    height: fit-content;
    min-width: 0;
}

.content-section {
    max-width: 800px;
    margin: clamp(48px, 8vw, 64px) auto;
    padding: 0 clamp(16px, 4vw, 24px);
}

.section-title {
    font-size: clamp(1.25rem, 4vw, 1.5rem);
    font-weight: 800;
    letter-spacing: -0.02em;
    margin-bottom: clamp(16px, 4vw, 24px);
    color: var(--text-1);
    text-align: center;
}

/* ═══════════════════════════════════════════
   HERO HEADER
   ═══════════════════════════════════════════ */
.hero {
    padding: clamp(32px, 8vw, 64px) 0 clamp(24px, 5vw, 40px);
    text-align: center;
}

.hero h1 {
    font-size: clamp(2rem, 5vw + 1rem, 3.5rem);
    font-weight: 800;
    letter-spacing: -0.04em;
    line-height: 1.1;
    color: var(--text-1);
    margin-bottom: 16px;
}

.hero p {
    font-size: clamp(1rem, 2vw + 0.5rem, 1.25rem);
    color: var(--text-2);
    font-weight: 400;
    max-width: 500px;
    margin: 0 auto;
    line-height: 1.6;
}

/* ═══════════════════════════════════════════
   CARD BASE
   ═══════════════════════════════════════════ */
.card {
    background: var(--surface);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-card);
    overflow: hidden;
    min-width: 0;
}

.card+.card {
    margin-top: 24px;
}

.card-section {
    padding: var(--space-card);
}

.card-section+.card-section {
    border-top: 1px solid var(--border-subtle);
}

.card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: var(--space-card);
    border-bottom: 1px solid var(--border-subtle);
}

.card-footer {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding: var(--space-card);
    border-top: 1px solid var(--border-subtle);
}

.card-footer-meta {
    display: flex;
    justify-content: center;
}

/* ═══════════════════════════════════════════
   FOOTER (PREMIUM REDESIGN)
   ═══════════════════════════════════════════ */
.site-footer {
    background: var(--bg);
    animation: fadeInFooter 0.8s ease forwards;
    opacity: 0;
    border-top: 1px solid var(--border-subtle);
}

@keyframes fadeInFooter {
    to {
        opacity: 1;
    }
}

.footer-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    max-width: 1100px;
    margin: 0 auto;
    padding: 48px 24px 32px;
}

.footer-col {
    display: flex;
    flex-direction: column;
}

.footer-brand-logo {
    position: relative;
    height: 48px;
    width: 360px;
    margin-bottom: 24px;
}

.footer-brand-logo img {
    max-height: 120px;
    width: auto;
    position: absolute;
    left: -16px;
    top: 50%;
    transform: translateY(-50%);
    transition: opacity 300ms var(--ease);
}

.footer-brand-desc {
    font-size: 0.9375rem;
    line-height: 1.7;
    color: var(--text-2);
    max-width: 380px;
}

.footer-nav {
    display: flex;
    flex-direction: row;
    gap: 12px;
    width: 100%;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.footer-nav a {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 24px;
    border-radius: 99px;
    background: var(--surface);
    border: 1px solid var(--border-subtle);
    color: var(--text-2);
    text-decoration: none;
    font-size: 0.9375rem;
    font-weight: 500;
    transition: all 300ms cubic-bezier(0.16, 1, 0.3, 1);
    width: auto;
}

.footer-nav a:hover {
    background-color: var(--accent);
    border-color: var(--accent);
    color: #ffffff;
    transform: translateY(-3px);
    box-shadow: 0 6px 16px rgba(16, 163, 127, 0.25);
}

.footer-nav a svg {
    transition: stroke 300ms ease;
}

.footer-bottom {
    max-width: 1100px;
    margin: 0 auto;
    padding: 16px 24px;
    border-top: 1px solid var(--border-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8125rem;
    color: var(--text-3);
    opacity: 0.8;
}

.footer-bottom p {
    margin: 0;
}