/* ═══════════════════════════════════════════════════════════
   MyPeptideApp — Layout Styles
   Sidebar, app header, bottom nav, page structure, responsive.
   ═══════════════════════════════════════════════════════════ */

/* ─── App Shell ────────────────────────────────────────── */
.app-layout {
    display: flex;
    min-height: 100vh;
    min-height: 100dvh;
}

.app-content {
    flex: 1;
    margin-left: var(--sidebar-width);
    height: 100vh;
    height: 100dvh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    position: relative;
}

.page-wrapper {
    flex: 1;
    padding: var(--space-6) var(--space-8);
    max-width: var(--content-max-width);
    width: 100%;
    margin: 0 auto;
}

/* ─── App Header (sticky on desktop) ──────────────────── */
.app-header {
    position: sticky;
    top: 0;
    z-index: var(--z-sticky);
    background: var(--color-header-blur);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    flex-shrink: 0;
}

.app-header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--space-4);
    height: var(--header-height);
    max-width: var(--content-max-width);
    width: 100%;
    margin: 0 auto;
    padding: 0 var(--space-8);
}

.app-header .page-title {
    font-size: var(--text-2xl);
    font-weight: var(--weight-bold);
    color: var(--color-text-primary);
    letter-spacing: -0.02em;
}

.app-header .page-subtitle {
    display: none;
}

.app-header .page-actions {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

/* ─── Legacy Page Header (keep for backwards compat) ──── */
.page-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-6);
    gap: var(--space-4);
}

.page-title {
    font-size: var(--text-2xl);
    font-weight: var(--weight-bold);
    color: var(--color-text-primary);
    letter-spacing: -0.02em;
}

.page-subtitle {
    font-size: var(--text-sm);
    color: var(--color-text-tertiary);
    margin-top: var(--space-1);
}

.page-actions {
    display: flex;
    align-items: center;
    gap: var(--space-3);
}

/* ─── Sidebar ──────────────────────────────────────────── */
.sidebar {
    position: fixed;
    top: 0;
    left: 0;
    width: var(--sidebar-width);
    height: 100vh;
    height: 100dvh;
    background: var(--color-bg-elevated);
    border-right: 1px solid var(--color-border-light);
    display: flex;
    flex-direction: column;
    z-index: var(--z-sidebar);
    transition: transform var(--duration-normal) var(--ease-out);
}

.sidebar-header {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: 0 var(--space-5);
    height: var(--header-height);
    border-bottom: 1px solid var(--color-border-light);
    flex-shrink: 0;
}

.sidebar-logo {
    width: 32px;
    height: 32px;
    background: var(--color-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-inverse);
    flex-shrink: 0;
    box-shadow: var(--shadow-xs);
}

.sidebar-brand {
    font-size: var(--text-lg);
    font-weight: var(--weight-bold);
    color: var(--color-text-primary);
    letter-spacing: -0.02em;
}

/* Navigation */
.sidebar-nav {
    flex: 1;
    padding: var(--space-4) var(--space-4);
    overflow-y: auto;
}

.nav-section {
    margin-bottom: var(--space-2);
}

.nav-section-label {
    padding: var(--space-2) var(--space-3);
    font-size: var(--text-xs);
    font-weight: var(--weight-semibold);
    color: var(--color-text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: 10px var(--space-3);
    border-radius: var(--radius-md);
    color: var(--color-text-secondary);
    font-size: 0.9rem;
    font-weight: var(--weight-normal);
    text-decoration: none;
    transition: all var(--duration-fast) var(--ease-in-out);
    margin-bottom: 2px;
}

.nav-item:hover {
    background: var(--color-bg-secondary);
    color: var(--color-text-primary);
}

.nav-item.active {
    background: var(--color-bg-tertiary);
    color: var(--color-text-primary);
}

.nav-item.active svg {
    color: var(--color-text-primary);
}

.nav-item svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
    color: var(--color-text-tertiary);
    transition: color var(--duration-fast) var(--ease-in-out);
}

.nav-item:hover svg {
    color: var(--color-text-secondary);
}

.nav-item .nav-badge {
    margin-left: auto;
}

/* ─── Collapsible Nav Group ───────────────────────────── */
.nav-collapsible {
    width: 100%;
    border: none;
    background: none;
    cursor: pointer;
    text-align: left;
}
.nav-collapsible-chevron {
    margin-left: auto;
    flex-shrink: 0;
    color: var(--color-text-tertiary);
    transition: transform var(--duration-fast) var(--ease-in-out);
}
.nav-collapsible.open .nav-collapsible-chevron {
    transform: rotate(180deg);
}
.nav-collapsible-items {
    overflow: hidden;
    max-height: 0;
    transition: max-height var(--duration-normal) var(--ease-out),
                opacity var(--duration-normal) var(--ease-out);
    opacity: 0;
}
.nav-collapsible-items.open {
    max-height: 200px;
    opacity: 1;
}
.nav-sub-item {
    padding-left: calc(var(--space-3) + 20px + var(--space-3)) !important;
    font-size: var(--text-sm) !important;
}
.nav-sub-item svg {
    width: 17px;
    height: 17px;
}

/* Sidebar Footer / Profile */
.sidebar-footer {
    padding: var(--space-3) var(--space-4);
    border-top: 1px solid var(--color-border-light);
}

.sidebar-profile {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    padding: var(--space-2) var(--space-3);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: background var(--duration-fast) var(--ease-in-out);
}

.sidebar-profile:hover {
    background: var(--color-bg-secondary);
}

.profile-avatar {
    width: 32px;
    height: 32px;
    border-radius: var(--radius-full);
    background: var(--color-bg-tertiary);
    border: 1px solid var(--color-border);
    color: var(--color-text-secondary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: var(--weight-semibold);
    font-size: var(--text-sm);
    flex-shrink: 0;
}

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

.profile-name {
    font-size: 0.9rem;
    font-weight: var(--weight-normal);
    color: var(--color-text-primary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    line-height: 1.3;
}

.profile-email {
    font-size: var(--text-xs);
    color: var(--color-text-tertiary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Profile dropdown */
.sidebar-dropdown {
    position: absolute;
    bottom: 64px;
    left: var(--space-3);
    right: var(--space-3);
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
    padding: var(--space-2);
    z-index: var(--z-dropdown);
    opacity: 0;
    visibility: hidden;
    transform: translateY(8px);
    transition: all var(--duration-fast) var(--ease-out);
}

.sidebar-dropdown.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sidebar-dropdown .nav-item {
    font-size: var(--text-sm);
}

.sidebar-dropdown .dropdown-divider {
    height: 1px;
    background: var(--color-border-light);
    margin: var(--space-2) 0;
}

/* Guest auth buttons in sidebar footer */
.sidebar-guest-auth {
    display: flex;
    flex-direction: column;
    gap: var(--space-2);
    padding: var(--space-1) 0;
}

.sidebar-guest-auth .btn {
    font-size: var(--text-sm);
    padding: var(--space-2) var(--space-4);
    justify-content: center;
}

.sidebar-guest-legal {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    padding-top: var(--space-3);
}

.sidebar-guest-legal a {
    font-size: var(--text-xs);
    color: var(--color-text-tertiary);
    text-decoration: none;
    transition: color var(--duration-fast);
}

.sidebar-guest-legal a:hover {
    color: var(--color-text-secondary);
}

.sidebar-guest-legal-dot {
    width: 3px;
    height: 3px;
    border-radius: var(--radius-full);
    background: var(--color-text-tertiary);
    flex-shrink: 0;
}

/* ─── Mobile Bottom Navigation ─────────────────────────── */
.bottom-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--color-bg-elevated);
    border-top: 1px solid var(--color-border);
    z-index: var(--z-sidebar);
    padding-bottom: env(safe-area-inset-bottom, 0);
}

.bottom-nav-items {
    display: flex;
    align-items: center;
    width: 100%;
    height: var(--bottom-nav-height);
}

.bottom-nav-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: var(--color-text-tertiary);
    font-size: 10px;
    font-weight: var(--weight-normal);
    text-decoration: none;
    transition: color var(--duration-fast) var(--ease-in-out);
    -webkit-tap-highlight-color: transparent;
    position: relative;
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
}

.bottom-nav-item svg {
    width: 24px;
    height: 24px;
    stroke-width: 1.5;
}

.bottom-nav-item.active {
    color: var(--color-primary);
    font-weight: var(--weight-medium);
}

.bottom-nav-item.active svg {
    stroke-width: 2;
}

.bottom-nav-item:active {
    transform: scale(0.94);
    transition: transform 0.1s ease;
}

/* More menu (slide-up sheet) */
.more-sheet-overlay {
    position: fixed;
    inset: 0;
    background: var(--color-overlay);
    z-index: var(--z-overlay);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--duration-normal) var(--ease-in-out),
                visibility var(--duration-normal);
}

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

.more-sheet {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--color-bg-elevated);
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    z-index: var(--z-modal);
    padding: var(--space-4) var(--space-4) var(--space-8);
    max-height: 70vh;
    overflow-y: auto;
    transform: translateY(100%);
    transition: transform var(--duration-normal) var(--ease-out);
}

.more-sheet-overlay.active .more-sheet {
    transform: translateY(0);
}

.more-sheet-handle {
    width: 36px;
    height: 4px;
    background: var(--color-border-strong);
    border-radius: var(--radius-full);
    margin: 0 auto var(--space-4);
}

.more-sheet .nav-item {
    padding: var(--space-3) var(--space-4);
    font-size: var(--text-md);
}

.more-sheet .sheet-divider {
    height: 1px;
    background: var(--color-border-light);
    margin: var(--space-2) 0;
}

.more-sheet-title {
    font-size: var(--text-xs);
    font-weight: var(--weight-semibold);
    color: var(--color-text-tertiary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: var(--space-2) var(--space-4);
    margin-top: var(--space-2);
}

/* ─── Auth Layout ──────────────────────────────────────── */
.auth-layout {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 100vh;
    padding: var(--space-4);
    padding-top: var(--space-16);
    padding-bottom: var(--space-12);
    background: var(--color-bg-secondary);
    position: relative;
}

/* ─── Back to Website Link ─────────────────────────────── */
.auth-back {
    position: absolute;
    top: var(--space-5);
    left: var(--space-5);
}

.auth-back-link {
    display: inline-flex;
    align-items: center;
    gap: var(--space-1);
    font-size: var(--text-sm);
    color: var(--color-text-tertiary);
    text-decoration: none;
    transition: color var(--duration-fast) var(--ease-in-out);
}

.auth-back-link:hover {
    color: var(--color-text-primary);
}

.auth-card {
    width: 100%;
    max-width: 420px;
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-xl);
    padding: var(--space-8);
    box-shadow: var(--shadow-md);
}

.auth-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-3);
    margin-bottom: var(--space-2);
}

.auth-logo-icon {
    width: 40px;
    height: 40px;
    background: var(--color-primary);
    border-radius: var(--radius-lg);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-inverse);
}

.auth-logo-text {
    font-size: var(--text-xl);
    font-weight: var(--weight-bold);
    color: var(--color-text-primary);
}

/* ─── Tagline ──────────────────────────────────────────── */
.auth-tagline {
    text-align: center;
    font-size: var(--text-sm);
    color: var(--color-text-tertiary);
    margin-bottom: var(--space-6);
}

/* ─── Free Badge (Register) ────────────────────────────── */
.auth-free-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-2);
    font-size: var(--text-xs);
    font-weight: var(--weight-medium);
    color: var(--color-success-dark);
    background: var(--color-success-light);
    border-radius: var(--radius-full);
    padding: var(--space-1) var(--space-4);
    margin-bottom: var(--space-6);
    width: fit-content;
    margin-left: auto;
    margin-right: auto;
}

/* ─── Inline Alert ─────────────────────────────────────── */
.auth-alert[hidden] {
    display: none;
}

.auth-alert {
    display: flex;
    align-items: flex-start;
    gap: var(--space-3);
    padding: var(--space-3) var(--space-4);
    border-radius: var(--radius-md);
    font-size: var(--text-sm);
    line-height: var(--leading-normal);
    margin-bottom: var(--space-5);
    animation: auth-alert-in var(--duration-normal) var(--ease-out);
}

.auth-alert-icon {
    flex-shrink: 0;
    margin-top: 1px;
}

.auth-alert-error {
    background: var(--color-danger-light);
    color: var(--color-danger-dark);
    border: 1px solid rgba(239, 68, 68, 0.2);
}

.auth-alert-warning {
    background: var(--color-warning-light);
    color: var(--color-warning-dark);
    border: 1px solid rgba(245, 158, 11, 0.2);
}

@keyframes auth-alert-in {
    from { opacity: 0; transform: translateY(-4px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ─── Form Label Link (e.g. "Forgot password?") ───────── */
.form-label-link {
    float: right;
    font-weight: var(--weight-normal);
    font-size: var(--text-xs);
    color: var(--color-text-tertiary);
    text-decoration: none;
}

.form-label-link:hover {
    color: var(--color-text-primary);
}

/* ─── Password Input Wrapper ──────────────────────────── */
.input-password-wrap {
    position: relative;
}

.input-password-wrap .form-input {
    padding-right: var(--space-10);
}

.password-toggle {
    position: absolute;
    right: var(--space-2);
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: none;
    border: none;
    color: var(--color-text-tertiary);
    cursor: pointer;
    border-radius: var(--radius-sm);
    transition: color var(--duration-fast) var(--ease-in-out);
}

.password-toggle:hover {
    color: var(--color-text-primary);
}

.password-toggle .icon-eye-off { display: none; }
.password-toggle.is-visible .icon-eye { display: none; }
.password-toggle.is-visible .icon-eye-off { display: block; }

/* ─── Password Strength Meter ─────────────────────────── */
.password-strength[hidden] {
    display: none;
}

.password-strength {
    display: flex;
    align-items: center;
    gap: var(--space-3);
    margin-top: var(--space-2);
}

.password-strength-track {
    flex: 1;
    height: 4px;
    background: var(--color-border);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.password-strength-fill {
    height: 100%;
    border-radius: var(--radius-full);
    transition: width var(--duration-normal) var(--ease-out),
                background-color var(--duration-normal) var(--ease-in-out);
    width: 0;
}

.password-strength-label {
    font-size: var(--text-xs);
    font-weight: var(--weight-medium);
    white-space: nowrap;
    min-width: 70px;
    text-align: right;
}

.str-very-weak  { background-color: var(--color-danger); }
.str-weak       { background-color: #F97316; }
.str-fair       { background-color: var(--color-warning); }
.str-good       { background-color: #84CC16; }
.str-strong     { background-color: var(--color-success); }
.str-very-strong { background-color: var(--color-success-dark); }

span.str-very-weak  { color: var(--color-danger); background: none; }
span.str-weak       { color: #F97316; background: none; }
span.str-fair       { color: var(--color-warning-dark); background: none; }
span.str-good       { color: #84CC16; background: none; }
span.str-strong     { color: var(--color-success); background: none; }
span.str-very-strong { color: var(--color-success-dark); background: none; }

/* ─── Social Proof ─────────────────────────────────────── */
.auth-social-proof {
    text-align: center;
    font-size: var(--text-xs);
    color: var(--color-text-tertiary);
    margin-top: var(--space-5);
    margin-bottom: calc(-1 * var(--space-1));
}

/* ─── Privacy Checkbox Links ──────────────────────────── */
.form-check a {
    color: var(--color-text-primary);
    font-weight: var(--weight-medium);
    text-decoration: underline;
    text-underline-offset: 2px;
}

.form-check a:hover {
    color: var(--color-primary);
}

.auth-footer {
    text-align: center;
    margin-top: var(--space-6);
    font-size: var(--text-sm);
    color: var(--color-text-tertiary);
}

.auth-footer a {
    color: var(--color-primary);
    font-weight: var(--weight-medium);
}

/* ─── Legal Footer ─────────────────────────────────────── */
.auth-legal-footer {
    margin-top: var(--space-8);
    text-align: center;
}

.auth-legal-links {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: var(--space-2);
    font-size: var(--text-xs);
}

.auth-legal-links a {
    color: var(--color-text-tertiary);
    text-decoration: none;
    transition: color var(--duration-fast) var(--ease-in-out);
}

.auth-legal-links a:hover {
    color: var(--color-text-primary);
}

.auth-legal-sep {
    color: var(--color-border-strong);
    user-select: none;
}

.auth-legal-copy {
    font-size: var(--text-xs);
    color: var(--color-text-tertiary);
    margin-top: var(--space-2);
    opacity: 0.7;
}

/* ═══ Success Screen ═════════════════════════════════════ */
.auth-success {
    text-align: center;
}

.auth-success.is-active {
    animation: auth-fade-in var(--duration-slow) var(--ease-out);
}

@keyframes auth-fade-in {
    from { opacity: 0; transform: translateY(8px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ─── Animated Checkmark ──────────────────────────────── */
.success-checkmark {
    width: 72px;
    height: 72px;
    margin: 0 auto var(--space-6);
}

.success-checkmark-svg {
    width: 72px;
    height: 72px;
}

.success-checkmark-circle {
    stroke-dasharray: 166;
    stroke-dashoffset: 166;
    stroke-width: 2;
    stroke-miterlimit: 10;
    stroke: var(--color-success);
    animation: success-circle 0.6s cubic-bezier(0.65, 0, 0.45, 1) forwards;
}

.success-checkmark-check {
    transform-origin: 50% 50%;
    stroke-dasharray: 48;
    stroke-dashoffset: 48;
    stroke-width: 3;
    stroke-linecap: round;
    stroke: var(--color-success);
    animation: success-check 0.35s cubic-bezier(0.65, 0, 0.45, 1) 0.5s forwards;
}

@keyframes success-circle {
    to { stroke-dashoffset: 0; }
}

@keyframes success-check {
    to { stroke-dashoffset: 0; }
}

.success-title {
    font-size: var(--text-xl);
    font-weight: var(--weight-bold);
    color: var(--color-text-primary);
    margin-bottom: var(--space-2);
}

.success-subtitle {
    font-size: var(--text-sm);
    color: var(--color-text-secondary);
    line-height: var(--leading-relaxed);
    margin-bottom: var(--space-6);
}

/* ─── Install CTA Card ────────────────────────────────── */
.success-install-card {
    display: flex;
    align-items: flex-start;
    gap: var(--space-4);
    text-align: left;
    background: var(--color-bg-tertiary);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-lg);
    padding: var(--space-5);
    margin-bottom: var(--space-6);
}

.success-install-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: var(--color-bg-elevated);
    border: 1px solid var(--color-border);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--color-text-secondary);
}

.success-install-content strong {
    display: block;
    font-size: var(--text-sm);
    font-weight: var(--weight-semibold);
    color: var(--color-text-primary);
    margin-bottom: var(--space-1);
}

.success-install-content p {
    font-size: var(--text-xs);
    color: var(--color-text-secondary);
    line-height: var(--leading-normal);
    margin-bottom: var(--space-2);
}

.success-install-link {
    font-size: var(--text-xs);
    font-weight: var(--weight-medium);
    color: var(--color-primary);
    text-decoration: none;
}

.success-install-link:hover {
    text-decoration: underline;
}

/* ─── Mobile Adjustments ──────────────────────────────── */
@media (max-width: 480px) {
    .auth-layout {
        padding-top: var(--space-12);
    }

    .auth-back {
        top: var(--space-3);
        left: var(--space-3);
    }

    .auth-card {
        padding: var(--space-6);
        border-radius: var(--radius-lg);
    }

    .success-install-card {
        flex-direction: column;
        gap: var(--space-3);
    }
}

/* ─── Card Grid (for Home) ─────────────────────────────── */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: var(--space-5);
}

/* ─── Section Spacing ──────────────────────────────────── */
.section {
    margin-bottom: var(--space-8);
}

.section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: var(--space-4);
}

.section-title {
    font-size: var(--text-lg);
    font-weight: var(--weight-semibold);
}

/* ─── Responsive ───────────────────────────────────────── */
@media (max-width: 1024px) {
    .page-wrapper {
        padding: var(--space-5) var(--space-6);
    }

    .app-header-inner {
        padding: 0 var(--space-6);
    }
}

@media (max-width: 768px) {
    /* Hide sidebar, show bottom nav */
    .sidebar {
        transform: translateX(-100%);
    }

    .sidebar.mobile-open {
        transform: translateX(0);
    }

    .app-content {
        margin-left: 0;
        height: auto;
        overflow-y: visible;
        overflow-x: hidden;
    }

    /* Header: not sticky on mobile, no background */
    .app-header {
        position: relative;
        background: transparent;
        backdrop-filter: none;
        -webkit-backdrop-filter: none;
    }

    .app-header-inner {
        padding: 0 var(--space-4);
        height: 56px;
    }

    .app-header .page-title {
        font-size: var(--text-2xl);
    }

    .bottom-nav {
        display: flex;
    }

    .page-wrapper {
        padding: var(--space-4) var(--space-4) calc(var(--bottom-nav-height) + var(--space-8));
        overflow-x: hidden;
    }

    .page-header {
        margin-bottom: var(--space-4);
    }

    .page-title {
        font-size: var(--text-2xl);
    }

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

    .table-responsive {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
    }
}

@media (max-width: 480px) {
    .page-wrapper {
        padding: var(--space-3) var(--space-3) calc(var(--bottom-nav-height) + var(--space-8));
    }

    .app-header-inner {
        padding: 0 var(--space-3);
    }

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

    .segmented-control {
        width: 100%;
    }

    .segment-btn {
        flex: 1;
        justify-content: center;
    }
}
