:root {
    --primary-gold: #ffcc00; /* The gold color from the top bar */
    --dark-text: #333;
    --light-text: #fff;
    --border-light: #eee;
    --shadow-light: rgba(0, 0, 0, 0.08);
    --body-bg: #f5f5f5; /* A very light grey for overall background */
    --card-bg: #fff;
    --ink: #1d1b2a;
    --ink-soft: #3d3952;
}
body {
    font-family: 'Fredoka', 'Arial', sans-serif;
    font-weight: 500;
    margin: 0;
    padding: 0;
    background-color: var(--body-bg);
    display: flex; /* Use flexbox for the main layout */
    justify-content: center; /* Center the app container */
    align-items: flex-start; /* Align to top */
    min-height: 100vh; /* Full viewport height */
    overflow: hidden;
    overscroll-behavior: none;
}

/* Outer container to simulate phone screen */
#app-container {
    width: 100%;
    max-width: 450px; /* Typical phone width range */
    background-color: #fff; /* White background for the app content */
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.1);
    display: flex;
    flex-direction: column;
    min-height: 100dvh; /* Ensures it stretches if content is short */
    height: 100dvh;
    overflow: hidden;
}

/* Header Styling */
.app-header {
    display: none; /* Hide the yellow banner */
}

.menu-icon, .notification-icon {
    font-size: 1.5em;
    cursor: pointer;
}

/* Main Content Area */
.main-content {
    flex-grow: 1; /* Allows main content to take available vertical space */
    padding: 20px;
    padding-bottom: 116px;
    overflow-y: auto; /* Enables scrolling if content overflows */
    overscroll-behavior: contain;
    -webkit-overflow-scrolling: touch;
    background: #f9eee3;
}

.options-section {
    margin-bottom: 25px;
    position: relative; /* For positioning the add button */
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.options-section h2 {
    color: var(--dark-text);
    font-size: 1.8em;
    margin: 0 0 2px;
    text-align: center;
}

.dashboard-progress-summary {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px;
    width: 100%;
}

.dashboard-progress-summary span {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    min-height: 30px;
    padding: 6px 11px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(29, 27, 42, 0.08);
    box-shadow: 0 6px 14px rgba(31, 30, 51, 0.06);
    color: var(--ink-soft);
    font-size: 0.92em;
    line-height: 1;
}

.dashboard-progress-summary strong {
    color: var(--ink);
    font-size: 1.05em;
}

.search-label {
    font-weight: bold;
    font-size: 1.1em;
    color: var(--dark-text);
    margin-bottom: 15px;
}

.add-button {
    display: none; /* Hidden as requested */
}

.add-button:hover {
    background-color: #45a049;
}

.back-button {
    margin-left: 0;
    margin-top: 8px;
    padding: 8px 14px;
    background: #e0e7ff;
    border: 1px solid #b7c2ff;
    border-radius: 20px;
    color: #1f3a93;
    cursor: pointer;
    font-weight: 700;
    display: inline-flex;
    align-items: center;
    gap: 2px;
}

.refresh-button {
    align-self: center;
    padding: 6px 12px;
    border-radius: 16px;
    border: 1px solid #c9d3ff;
    background: #f4f7ff;
    color: #1f3a93;
    font-weight: 600;
    cursor: pointer;
}

.refresh-button:active {
    transform: translateY(1px);
}

.back-button.hidden {
    display: none;
}

.search-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    border: 1px solid #ffd6e8;
    border-radius: 28px;
    padding: 10px 14px;
    background: linear-gradient(120deg, #fff7fb 0%, #ffe6f2 100%);
    box-shadow: 0 4px 12px rgba(255, 165, 200, 0.25);
    transition: all 0.25s ease;
    width: min(90%, 360px);
}

.search-bar.collapsed {
    width: 34px;
    height: 31px;
    padding: 7px;
    justify-content: center;
    gap: 0;
    cursor: pointer;
}

.search-bar.collapsed .search-input {
    display: none;
}

.search-input {
    flex-grow: 1;
    border: none;
    outline: none;
    padding: 8px 4px;
    font-size: 1em;
    background: transparent;
    color: #444;
}

.search-input::placeholder {
    color: #a77ea1;
}

.search-icon {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(160deg, #ffb3cc 0%, #ffcce0 100%);
    color: #7b3d6e;
    font-size: 1.2em;
    box-shadow: 0 2px 6px rgba(123, 61, 110, 0.25);
}


/* Lessons List (Container for cards) */
.lessons-list {
    display: flex;
    flex-direction: column;
    gap: 15px; /* Space between lesson cards */
    padding: 0 12px; /* Pull cards away from screen edges */
}

/* Individual Lesson Card Styling (The items like "A / An", "Science Experiment") */
.lesson-card {
    display: flex;
    align-items: center;
    position: relative;
    background: radial-gradient(circle at center, #ffffff 70%, #f2f8ff 90%, #cfe5ff 100%);
    border: 5px #000000;
    box-shadow: inset 0 0 0 2px #7fbaff, inset 0 0 32px 18px #d7ebff, 0 10px 24px rgba(120, 170, 220, 0.35);
    border-radius: 10px;
    padding: 15px;
    cursor: pointer;
    font-size: 20px;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    -webkit-box-reflect: below 2px linear-gradient(transparent 10%, rgba(120, 170, 220, 0.22) 100%);
}

.lesson-card.is-completed {
    background: radial-gradient(circle at center, #ffffff 62%, #f5fff2 86%, #ffe9a8 100%);
    box-shadow: inset 0 0 0 2px rgba(92, 183, 91, 0.58), inset 0 0 28px 14px rgba(235, 255, 223, 0.9), 0 10px 24px rgba(134, 169, 72, 0.28);
}

.lesson-badge {
    position: absolute;
    top: 8px;
    right: 10px;
    padding: 4px 8px;
    border-radius: 10px;
    font-size: 0.75em;
    font-weight: 700;
    letter-spacing: 0.02em;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.lesson-badge.free {
    background: #e7f8ed;
    color: #11623a;
    border: 1px solid #bce7cd;
}

.lesson-badge.completed {
    background: linear-gradient(135deg, #e9fff0, #fff0b8);
    color: #226238;
    border: 1px solid #9fd98a;
    box-shadow: 0 6px 12px rgba(70, 143, 68, 0.14);
}

.lesson-badge.in-progress {
    background: #fff7de;
    color: #8a5a00;
    border: 1px solid #f6d98b;
}

.lesson-badge.locked {
    background: #fff1f2;
    color: #9f1239;
    border: 1px solid #fecdd3;
}

.lesson-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.lesson-thumbnail {
    width: 60px; /* Fixed size for the thumbnail */
    height: 60px;
    border-radius: 55px; /* Slightly rounded corners for images */
    object-fit: cover; /* Ensures image covers the area without distortion */
    transform: scale(1);
    margin-right: 15px;
}

.lesson-info {
    flex-grow: 1; /* Allows info to take available space */
    min-width: 0;
    text-align: left;
}

.lesson-info h3 {
    margin: 0 0 5px 0;
    font-size: 1.15em;
    color: var(--dark-text);
}

.lesson-info p {
    margin: 0;
    font-size: 0.9em;
    color: #666;
    line-height: 1.4;
}

.lesson-progress {
    display: grid;
    gap: 5px;
    margin-top: 8px;
    max-width: 220px;
}

.lesson-progress-meta {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    color: #5f6070;
    font-size: 0.68em;
    line-height: 1;
}

.lesson-progress-meta strong {
    color: #26324a;
    font-weight: 800;
}

.lesson-progress-track {
    width: 100%;
    height: 7px;
    overflow: hidden;
    border-radius: 999px;
    background: rgba(38, 50, 74, 0.12);
}

.lesson-progress-fill {
    display: block;
    height: 100%;
    min-width: 0;
    border-radius: inherit;
    background: linear-gradient(90deg, #ff9f6e, #43c59e);
    transition: width 180ms ease;
}

.lesson-stars {
    display: inline-flex;
    gap: 3px;
    margin-top: 8px;
    line-height: 1;
}

.lesson-star {
    color: rgba(38, 50, 74, 0.18);
    font-size: 1.18em;
    text-shadow: 0 1px 0 rgba(255, 255, 255, 0.8);
}

.lesson-star.earned {
    color: #f4b400;
    text-shadow: 0 1px 0 rgba(116, 80, 0, 0.18);
}

.forward-arrow {
    font-size: 1.5em;
    color: #999;
    margin-left: 15px;
}

/* Bottom Navigation Bar */
.bottom-nav {
    position: fixed;
    left: 50%;
    bottom: 0;
    transform: translateX(-50%);
    width: min(430px, calc(100% - 20px));
    background: rgba(255, 251, 246, 0.98);
    backdrop-filter: blur(10px);
    border-top: 1px solid rgba(29, 27, 42, 0.08);
    border-left: 1px solid rgba(29, 27, 42, 0.04);
    border-right: 1px solid rgba(29, 27, 42, 0.04);
    border-radius: 18px 18px 0 0;
    padding: 8px 18px calc(8px + env(safe-area-inset-bottom));
    display: flex;
    justify-content: space-around;
    gap: 12px;
    box-shadow: 0 -10px 24px rgba(31, 30, 51, 0.08);
    z-index: 2;
}

.nav-button {
    border: none;
    background: transparent;
    border: none;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    font-family: inherit;
    font-size: 15px;
    color: var(--ink-soft);
    padding: 8px 10px;
    border-radius: 16px;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.nav-button img {
    width: 51px;
    height: 48px;
}

.nav-button.active {
    background: linear-gradient(135deg, rgba(255, 123, 93, 0.2), rgba(244, 86, 78, 0.2));
    color: var(--ink);
    transform: translateY(-2px);
}

.nav-button:active {
    transform: translateY(0);
}

/* Account screen (in-app) */
#account-screen {
    display: none;
    margin: -20px;
    padding: 20px 20px 0;
    min-height: 100%;
    background: linear-gradient(180deg, #fff8ef 0%, #fffdf8 42%, #f9eee3 100%);
}

#account-screen .account-screen {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

#account-screen .account-card {
    background: rgba(255, 255, 255, 0.9);
    border-radius: 22px;
    padding: 22px;
    border: 1px solid rgba(29, 27, 42, 0.12);
    box-shadow: 0 18px 40px rgba(31, 30, 51, 0.16);
    /* margin-top: 100px; */
}

#account-screen .account-title {
    margin: 0 0 6px;
    font-size: 1.2em;
    color: #1d1b2a;
}

#account-screen .account-brand {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 8px;
    font-weight: 700;
    color: #1d1b2a;
    font-size: 23px;
}

#account-screen .account-brand img {
    width: 68px;
    height: 68px;
    border-radius: 8px;
    object-fit: cover;
}

#account-screen .account-subtitle {
    margin: 0 0 14px;
    color: #3d3952;
    font-size: 0.9em;
}

#account-screen .auth-mode-switch {
    display: flex;
    justify-content: flex-start;
    margin: 14px 0 8px;
}

#account-screen .auth-mode-button {
    border: 1px solid rgba(29, 27, 42, 0.12);
    border-radius: 12px;
    background: rgba(29, 27, 42, 0.06);
    color: #1d1b2a;
    font-size: 0.95em;
    font-weight: 700;
    padding: 11px 14px;
    cursor: pointer;
}

#account-screen .auth-mode-button.is-active {
    color: white;
    background: linear-gradient(135deg, #ff7b5d, #f4564e);
    box-shadow: 0 14px 30px rgba(244, 86, 78, 0.18);
    border-color: transparent;
}

#account-screen .auth-panel[hidden] {
    display: none;
}

#account-screen .status-list {
    display: grid;
    gap: 10px;
    margin: 16px 0 6px;
}

#account-screen .status-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 12px;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.8);
    border: 1px solid rgba(29, 27, 42, 0.08);
    font-size: 0.95em;
}

#account-screen .status-item span {
    color: #3d3952;
}

#account-screen .status-item strong {
    color: #1d1b2a;
}

#account-screen .login-form {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-top: 30px;
    
    
}

#account-screen .login-form button {
    color: white;
    background: linear-gradient(135deg, #ff7b5d, #f4564e);
    box-shadow: 0 14px 30px rgba(244, 86, 78, 0.28);
    border: none;
    border-radius: 10px;
    padding: 12px 14px;
    font-size: 0.95em;
    font-weight: 700;
}

#account-screen label {
    font-weight: 700;
    font-size: 0.9em;
    color: #333;
}

#account-screen input {
    border-radius: 12px;
    border: 1px solid rgba(29, 27, 42, 0.18);
    padding: 12px 14px;
    font-size: 1em;
}

#account-screen .button-row {
    display: grid;
    gap: 10px;
    margin-top: 14px;
}

#account-screen .primary-button,
#account-screen .secondary-button,
#account-screen .google-button,
#account-screen .ghost-button {
    border: 20px;
    border-radius: 10px;
    padding: 12px 14px;
    font-size: 0.95em;
    font-weight: 700;
    cursor: pointer;
    color: white;
    
}

#account-screen .primary-button {
    color: white;
    background: linear-gradient(135deg, #ff7b5d, #f4564e);
    box-shadow: 0 14px 30px rgba(244, 86, 78, 0.28);
}

#account-screen .secondary-button {
    background: rgba(29, 27, 42, 0.06);
    color: #1d1b2a;
}

#account-screen .google-button {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    min-height: 52px;
    padding: 14px 18px;
    background: #ffffff;
    color: #1d1b2a;
    border: 1px solid rgba(29, 27, 42, 0.16);
    border-radius: 14px;
    box-shadow: 0 12px 28px rgba(31, 30, 51, 0.1);
    font-size: 1em;
    transition: transform 160ms ease, box-shadow 160ms ease, border-color 160ms ease;
}

#account-screen .google-button:hover {
    border-color: rgba(29, 27, 42, 0.24);
    box-shadow: 0 16px 34px rgba(31, 30, 51, 0.14);
    transform: translateY(-1px);
}

#account-screen .google-button:focus-visible {
    outline: 3px solid rgba(66, 133, 244, 0.28);
    outline-offset: 3px;
}

#account-screen .google-button:disabled {
    cursor: wait;
    opacity: 0.72;
    transform: none;
}

#account-screen .google-button-logo {
    flex: 0 0 auto;
    width: 24px;
    height: 24px;
}

#account-screen .ghost-button {
    color: #1d1b2a;
    background: rgba(29, 27, 42, 0.06);
    /* box-shadow: 0 14px 30px rgba(244, 86, 78, 0.28); */
    border: none;
    margin-top: 20px;
    border-radius: 10px;
    padding: 10px 14px;
    font-size: 0.95em;
    font-weight: 700;
}

.status-badge {
    margin: 10px 0 14px;
    padding: 10px 14px;
    border-radius: 999px;
    font-weight: 700;
    display: inline-block;
    letter-spacing: 0.02em;
  }
  
  .status-locked {
    background: rgba(255, 232, 192, 0.95);
    color: #8a4b00;
    border: 1px solid rgba(207, 138, 19, 0.28);
  }
  
  .status-unlocked {
    background: rgba(229, 255, 237, 0.95);
    color: #0f6a3f;
    border: 1px solid rgba(15, 106, 63, 0.18);
  }
  
.login-card {
    position: relative;
    overflow: hidden;
    background:
      radial-gradient(circle at top left, rgba(255, 216, 186, 0.95), transparent 34%),
      radial-gradient(circle at top right, rgba(193, 231, 255, 0.9), transparent 32%),
      linear-gradient(180deg, #fffdf8 0%, #ffffff 100%);
    border-radius: 28px;
    padding: 22px 22px 110px;
    border: 1px solid rgba(31, 30, 51, 0.08);
    box-shadow: 0 22px 44px rgba(31, 30, 51, 0.14);
    min-height: calc(100dvh - 20px);
}

.account-hero {
    position: relative;
    border-radius: 24px;
    padding: 18px;
    color: #1f1d2c;
    overflow: hidden;
}

.account-hero::after {
    content: "";
    position: absolute;
    inset: auto -40px -46px auto;
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.24);
    filter: blur(2px);
}

.account-hero.is-premium {
    background: linear-gradient(135deg, #7bc8ff 0%, #b5e1ff 44%, #fff2cf 100%);
}

.account-hero.is-limited {
    background: linear-gradient(135deg, #7bc8ff 0%, #b5e1ff 44%, #fff2cf 100%);
}

.account-hero-top {
    display: flex;
    align-items: center;
    gap: 14px;
    position: relative;
    z-index: 1;
}

.profile-mark {
    appearance: none;
    width: 60px;
    height: 60px;
    flex: 0 0 60px;
    padding: 0;
    border: 2px solid rgba(255, 255, 255, 0.78);
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: blur(6px);
    overflow: hidden;
    cursor: pointer;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.5);
    transition: transform 160ms ease, box-shadow 160ms ease;
}

.profile-mark:hover,
.profile-mark:focus-visible {
    transform: translateY(-2px);
    outline: none;
    box-shadow: 0 12px 22px rgba(36, 29, 48, 0.14), inset 0 0 0 1px rgba(255, 255, 255, 0.5);
}

.profile-mark img {
    width: 100%;
    height: 100%;
    display: block;
    object-fit: cover;
}

.card-header {
    position: relative;
    z-index: 1;
}

.eyebrow {
    margin: 0 0 4px;
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    opacity: 0.74;
}

.card-header h2 {
    margin: 0;
    font-size: 1.45rem;
    line-height: 1.15;
}

.hero-subtitle {
    margin: 8px 0 0;
    max-width: 28ch;
    color: rgba(31, 29, 44, 0.8);
    font-size: 0.95rem;
    line-height: 1.45;
}

.hero-chips {
    position: relative;
    z-index: 1;
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
}

.hero-chip {
    display: inline-flex;
    align-items: center;
    padding: 8px 12px;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.75);
    border: 1px solid rgba(255, 255, 255, 0.45);
    font-size: 0.84rem;
    font-weight: 700;
    color: #2a2738;
    text-transform: capitalize;
}

.account-stats {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 14px;
}

.account-stat {
    padding: 14px 12px;
    border-radius: 18px;
    background: linear-gradient(180deg, rgba(236, 247, 255, 0.98) 0%, rgba(248, 252, 255, 0.96) 100%);
    border: 1px solid rgba(123, 200, 255, 0.24);
    box-shadow: 0 16px 30px rgba(123, 200, 255, 0.12);
}

.account-stat-label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.76rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #7a6c61;
}

.account-stat-value {
    display: block;
    color: #201d2d;
    font-size: 0.98rem;
    line-height: 1.35;
    word-break: break-word;
}

.premium-box {
    margin-top: 16px;
    padding: 18px;
    border-radius: 22px;
    background: linear-gradient(180deg, rgba(236, 247, 255, 0.98) 0%, rgba(248, 252, 255, 0.96) 100%);
    border: 1px solid rgba(123, 200, 255, 0.24);
    box-shadow: 0 16px 30px rgba(123, 200, 255, 0.12);
}

.avatar-modal[hidden],
.avatar-prompt[hidden],
.avatar-grid-panel[hidden] {
    display: none;
}

.avatar-modal {
    position: fixed;
    inset: 0;
    z-index: 20;
    display: grid;
    place-items: center;
    padding: 22px;
}

.avatar-modal-backdrop {
    position: absolute;
    inset: 0;
    border: none;
    background: rgba(31, 29, 44, 0.42);
    cursor: pointer;
}

.avatar-picker-box {
    position: relative;
    z-index: 1;
    width: min(520px, 100%);
    max-height: calc(100dvh - 44px);
    overflow: auto;
    padding-bottom: 16px;
}

.avatar-prompt {
    text-align: center;
}

.avatar-prompt-image {
    width: 104px;
    height: 104px;
    display: block;
    margin: 0 auto 14px;
    border-radius: 18px;
    object-fit: cover;
    box-shadow: 0 14px 24px rgba(36, 29, 48, 0.12);
}

.avatar-modal-actions {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
    margin-top: 16px;
}

.avatar-picker {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(92px, 1fr));
    gap: 12px;
}

.avatar-choice {
    appearance: none;
    min-width: 0;
    border: 2px solid transparent;
    border-radius: 8px;
    padding: 8px;
    background: rgba(255, 255, 255, 0.76);
    box-shadow: 0 10px 18px rgba(36, 29, 48, 0.08);
    cursor: pointer;
    transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
}

.avatar-choice:hover,
.avatar-choice:focus-visible {
    transform: translateY(-2px);
    border-color: rgba(255, 122, 89, 0.68);
    outline: none;
    box-shadow: 0 14px 24px rgba(36, 29, 48, 0.12);
}

.avatar-choice.is-selected {
    border-color: #ff7a59;
    background: #fff5ee;
    box-shadow: 0 14px 26px rgba(239, 68, 68, 0.18);
}

.avatar-choice img {
    width: 100%;
    aspect-ratio: 1;
    display: block;
    border-radius: 6px;
    object-fit: cover;
}

.avatar-choice span {
    display: block;
    margin-top: 8px;
    color: #241d30;
    font-size: 0.88rem;
    font-weight: 800;
    line-height: 1.15;
    text-align: center;
}

.avatar-save-status {
    min-height: 1.2em;
    margin: 12px 2px 0;
    color: #746969;
    font-size: 0.9rem;
}

.progress-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
    margin-top: 14px;
}

.progress-item {
    padding: 14px 12px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(123, 200, 255, 0.2);
}

.progress-label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.76rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: #7a6c61;
}

.progress-value {
    display: block;
    color: #201d2d;
    font-size: 0.98rem;
    line-height: 1.35;
    word-break: break-word;
}

.premium-title {
    margin: 0 0 8px 0;
    color: #2a2235;
    font-size: 1.12rem;
}

.premium-sub {
    margin: 0 0 12px 0;
    color: #5a4d45;
    line-height: 1.55;
}

.premium-list {
    margin: 0 0 14px 18px;
    padding: 0;
    color: #3f384c;
    line-height: 1.7;
}

.price-row {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    align-items: baseline;
    margin: 12px 0 0;
    padding-top: 12px;
    border-top: 1px solid rgba(42, 34, 53, 0.08);
}

.price-label {
    color: #6b5f59;
    font-size: 0.9rem;
}

.price-value {
    font-weight: 800;
    color: #241d30;
    text-align: right;
}

.cta-row,
.account-actions {
    display: grid;
    gap: 10px;
}

.cta-row {
    margin-top: 16px;
}

.account-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    margin-top: 18px;
}

.primary-btn,
.ghost-btn {
    width: 100%;
    border-radius: 16px;
    padding: 13px 16px;
    font-size: 0.96rem;
    font-weight: 800;
    cursor: pointer;
}

.primary-btn {
    border: none;
    color: white;
    background: linear-gradient(135deg, #ff7a59 0%, #ef4444 100%);
    box-shadow: 0 16px 26px rgba(239, 68, 68, 0.24);
}

.primary-btn:disabled {
    cursor: wait;
    opacity: 0.72;
}

.ghost-btn {
    background: rgba(255, 255, 255, 0.9);
    color: #241d30;
    border: 1px solid rgba(36, 29, 48, 0.12);
    box-shadow: 0 10px 20px rgba(36, 29, 48, 0.06);
}

.payment-status {
    min-height: 1.35em;
    margin: 12px 2px 0;
    color: #746969;
    font-size: 0.9rem;
    line-height: 1.5;
}

.payment-status[data-state="pending"] {
    color: #8a5a00;
}

.payment-status[data-state="success"] {
    color: #0f6a3f;
}

.payment-status[data-state="error"] {
    color: #9f1239;
}

.account-note {
    margin: 14px 2px 0;
    color: #746969;
}

@media (max-width: 480px) {
    #account-screen {
        margin: -20px;
        padding: 0;
    }

    .login-card {
        min-height: 100dvh;
        border-radius: 0;
        border-left: none;
        border-right: none;
        border-top: none;
        box-shadow: none;
        padding: 18px 16px 110px;
    }

    .account-hero {
        border-radius: 0 0 24px 24px;
        margin: -18px -16px 0;
        padding: 20px 16px 18px;
    }

    .account-stats {
        grid-template-columns: 1fr;
    }

    .account-actions {
        grid-template-columns: 1fr;
    }

    .avatar-modal {
        align-items: end;
        padding: 14px;
    }

    .avatar-picker-box {
        width: 100%;
        border-radius: 22px;
    }

    .avatar-modal-actions {
        grid-template-columns: 1fr;
    }

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

    .card-header h2 {
        font-size: 1.28rem;
    }
}
