/* --- GMAIL THEME VARIABLES & GLOBAL STYLES --- */
:root {
    --bg-page: #f6f8fc;
    --bg-surface: #ffffff;
    --bg-search: #eaf1fb;
    --bg-search-hover: #dfe7f6;
    --bg-pill-active: #c2e7ff;
    --text-primary: #1f1f1f;
    --text-secondary: #444746;
    --text-muted: #5e5e5e;
    --primary-blue: #0b57d0;
    --primary-blue-dark: #0842a0;
    --border-color: #e0e2ec;
    --border-subtle: #f0f2f7;
    --unread-row-bg: #f2f6fc;
    --read-row-bg: #ffffff;
    --row-hover-bg: #f5f7fb;
    --font-family: 'Open Sans', 'Roboto', -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body.gmail-body {
    font-family: var(--font-family);
    background-color: var(--bg-page);
    color: var(--text-primary);
    overflow-x: hidden;
    min-height: 100vh;
}

/* --- HEADER --- */
.gmail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    height: 64px;
    background-color: var(--bg-page);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 240px;
}

.icon-btn {
    background: none;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-secondary);
    transition: background 0.2s;
}

.icon-btn:hover {
    background-color: rgba(68, 71, 70, 0.08);
}

.brand-logo {
    display: inline-flex;
    align-items: center;
    text-decoration: none;
    height: 44px;
}

.brand-logo-img {
    height: 38px;
    width: auto;
    max-width: 200px;
    object-fit: contain;
    display: block;
}

/* SEARCH & ACTIVE EMAIL BAR */
.header-center {
    flex: 1;
    max-width: 720px;
    margin: 0 16px;
}

.email-search-bar {
    display: flex;
    align-items: center;
    background-color: var(--bg-search);
    border-radius: 30px;
    padding: 4px 14px 4px 18px;
    height: 48px;
    transition: background 0.2s, box-shadow 0.2s;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
}

.email-search-bar:hover,
.email-search-bar:focus-within {
    background-color: var(--bg-surface);
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.16);
}

.search-icon {
    display: flex;
    align-items: center;
    color: var(--text-muted);
    margin-right: 12px;
}

.current-email-wrapper {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.active-email-text {
    font-size: 15px;
    font-weight: 600;
    color: var(--primary-blue);
    letter-spacing: 0.2px;
    user-select: all;
}

.email-action-pills {
    display: flex;
    align-items: center;
    gap: 6px;
}

.pill-action-btn {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
}

.pill-action-btn.primary {
    background-color: var(--primary-blue);
    color: #ffffff;
}

.pill-action-btn.primary:hover {
    background-color: var(--primary-blue-dark);
}

.pill-action-btn.secondary {
    background-color: rgba(11, 87, 208, 0.08);
    color: var(--primary-blue);
}

.pill-action-btn.secondary:hover {
    background-color: rgba(11, 87, 208, 0.16);
}

.pill-action-btn.icon-only {
    padding: 6px 8px;
    background-color: transparent;
    color: var(--text-secondary);
}

.pill-action-btn.icon-only:hover {
    background-color: rgba(68, 71, 70, 0.1);
}

.header-right {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 240px;
    justify-content: flex-end;
}

.profile-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: #ea4335;
    color: #ffffff;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    cursor: pointer;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.2);
}

/* --- APP CONTAINER --- */
.gmail-container {
    display: flex;
    height: calc(100vh - 64px);
    overflow: hidden;
}

/* --- SIDEBAR --- */
.gmail-sidebar {
    width: 256px;
    background-color: var(--bg-page);
    padding: 8px 12px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    flex-shrink: 0;
    transition: width 0.2s;
}

.sidebar-compose {
    margin: 8px 0 16px 0;
}

.compose-btn {
    display: inline-flex;
    align-items: center;
    gap: 12px;
    background-color: var(--bg-pill-active);
    color: #001d35;
    padding: 0 24px;
    height: 56px;
    border-radius: 16px;
    border: none;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    transition: box-shadow 0.2s, background 0.2s;
}

.compose-btn:hover {
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.15);
    background-color: #b0defa;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 2px;
    flex: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 16px;
    height: 36px;
    padding: 0 16px 0 20px;
    border-radius: 0 18px 18px 0;
    text-decoration: none;
    color: var(--text-secondary);
    font-size: 14px;
    font-weight: 500;
    margin-right: 8px;
    transition: background 0.15s;
}

.nav-item:hover {
    background-color: rgba(68, 71, 70, 0.08);
    color: var(--text-primary);
}

.nav-item.active {
    background-color: var(--bg-pill-active);
    color: #001d35;
    font-weight: 700;
}

.nav-badge {
    margin-left: auto;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-primary);
}

.sidebar-divider {
    height: 1px;
    background-color: var(--border-color);
    margin: 14px 12px;
}

.sidebar-section-title {
    font-size: 11px;
    font-weight: 700;
    color: var(--text-muted);
    letter-spacing: 0.8px;
    padding: 8px 16px 4px 20px;
}

.sidebar-storage {
    padding: 16px;
    margin-top: auto;
}

.storage-text {
    font-size: 12px;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.storage-bar {
    height: 4px;
    background-color: #e0e2ec;
    border-radius: 2px;
    overflow: hidden;
}

.storage-fill {
    height: 100%;
    background-color: var(--primary-blue);
    border-radius: 2px;
}

/* --- MAIN CONTENT AREA --- */
.gmail-main {
    flex: 1;
    background-color: var(--bg-surface);
    border-radius: 16px 16px 0 0;
    margin-right: 16px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.main-toolbar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 16px;
    border-bottom: 1px solid var(--border-subtle);
    height: 48px;
}

.toolbar-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.checkbox-container {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    cursor: pointer;
    transition: background-color 0.15s ease;
}

.checkbox-container:hover {
    background-color: rgba(68, 71, 70, 0.1);
}

.checkbox-container input[type="checkbox"],
.msg-cb {
    cursor: pointer;
    width: 17px;
    height: 17px;
    accent-color: var(--primary-blue);
    margin: 0;
}

.icon-btn-small {
    background: none;
    border: none;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-secondary);
    transition: all 0.15s ease;
}

.icon-btn-small:hover {
    background-color: rgba(68, 71, 70, 0.12);
    color: var(--text-primary);
}

.icon-btn-small:active {
    transform: scale(0.9);
}

#toolbar-delete-btn:hover {
    color: #d93025;
    background-color: rgba(217, 48, 37, 0.12);
}

#toolbar-refresh-btn:hover {
    color: var(--primary-blue);
    background-color: rgba(11, 87, 208, 0.12);
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* SIMULATOR BUTTONS */
.toolbar-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.sim-text {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 600;
}

.sim-btn {
    background-color: var(--bg-page);
    border: 1px solid var(--border-color);
    padding: 4px 10px;
    border-radius: 14px;
    font-size: 12px;
    cursor: pointer;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all 0.15s;
}

.sim-btn:hover {
    background-color: var(--bg-search);
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

/* CATEGORY TABS (PRIMARY) - CENTERED */
.category-tabs {
    display: flex;
    justify-content: center;
    border-bottom: 1px solid var(--border-subtle);
    background-color: var(--bg-surface);
}

.cat-tab {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 14px 36px;
    background: none;
    border: none;
    border-bottom: 3px solid transparent;
    cursor: pointer;
    color: var(--text-muted);
    font-size: 15px;
    font-weight: 600;
    transition: all 0.2s;
}

.cat-tab:hover {
    background-color: var(--row-hover-bg);
    color: var(--text-primary);
}

.cat-tab.active {
    color: var(--primary-blue);
    border-bottom-color: var(--primary-blue);
}

/* EMAIL LIST CONTAINER */
.email-list-container {
    flex: 1;
    overflow-y: auto;
    position: relative;
}

/* EMPTY INBOX (RADAR WAITING) */
.empty-inbox-state {
    padding: 60px 20px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 580px;
    margin: 0 auto;
}

.pulse-radar {
    position: relative;
    width: 80px;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
}

.radar-dot {
    width: 18px;
    height: 18px;
    background-color: var(--primary-blue);
    border-radius: 50%;
    z-index: 2;
}

.radar-ring, .radar-ring-2 {
    position: absolute;
    width: 100%;
    height: 100%;
    border: 2px solid var(--primary-blue);
    border-radius: 50%;
    animation: radar-pulse 2s linear infinite;
    opacity: 0;
}

.radar-ring-2 {
    animation-delay: 1s;
}

@keyframes radar-pulse {
    0% { transform: scale(0.3); opacity: 0.8; }
    100% { transform: scale(1.6); opacity: 0; }
}

.empty-inbox-state h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.empty-subtitle {
    font-size: 14px;
    color: var(--text-muted);
    line-height: 1.5;
    margin-bottom: 28px;
}

.instructions-card {
    display: flex;
    flex-direction: column;
    gap: 14px;
    background-color: var(--bg-page);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 20px;
    width: 100%;
    text-align: left;
}

.step-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.step-num {
    background-color: var(--primary-blue);
    color: #ffffff;
    font-weight: 700;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    flex-shrink: 0;
}

.step-item strong {
    font-size: 14px;
    color: var(--text-primary);
}

.step-item p {
    font-size: 13px;
    color: var(--text-muted);
    margin-top: 2px;
}

/* MESSAGE ROWS */
.message-row {
    display: flex;
    align-items: center;
    padding: 10px 16px;
    border-bottom: 1px solid var(--border-subtle);
    cursor: pointer;
    background-color: var(--read-row-bg);
    transition: background 0.15s, box-shadow 0.15s;
    user-select: none;
}

.message-row:hover {
    box-shadow: inset 1px 0 0 #dadce0, inset -1px 0 0 #dadce0, 0 1px 2px 0 rgba(60,64,67,.3), 0 1px 3px 1px rgba(60,64,67,.15);
    background-color: var(--row-hover-bg);
    z-index: 1;
}

.message-row.unread {
    background-color: var(--unread-row-bg);
    font-weight: 700;
}

.message-row.selected {
    background-color: #c2dbff !important;
}

.message-row.unread .msg-sender {
    color: var(--text-primary);
    font-weight: 700;
}

.msg-actions {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-right: 14px;
}

.star-icon {
    color: #c4c7c5;
    cursor: pointer;
}

.star-icon.starred {
    color: #fbbc04;
}

.msg-sender {
    width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    font-size: 14px;
    color: var(--text-secondary);
}

.msg-snippet-box {
    flex: 1;
    display: flex;
    align-items: center;
    gap: 8px;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
    font-size: 14px;
    margin: 0 16px;
}

.msg-subject {
    color: var(--text-primary);
}

.msg-snippet-preview {
    color: var(--text-muted);
    font-weight: 400;
}

.otp-pill {
    background-color: #e8f0fe;
    color: #1a73e8;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
}

.msg-time {
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 600;
    white-space: nowrap;
}

/* --- EMAIL DETAIL VIEW --- */
.email-detail-container {
    padding: 16px 24px;
    overflow-y: auto;
    height: 100%;
}

.detail-action-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-subtle);
    margin-bottom: 20px;
}

.back-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: none;
    border: none;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
}

.back-btn:hover {
    color: var(--primary-blue);
}

.email-subject-title {
    font-size: 22px;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 20px;
}

.sender-row {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 24px;
}

.sender-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background-color: var(--primary-blue);
    color: #ffffff;
    font-size: 18px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
}

.sender-info {
    flex: 1;
}

.sender-line {
    font-size: 14px;
}

.sender-name {
    color: var(--text-primary);
    font-weight: 700;
}

.sender-email-bracket {
    color: var(--text-muted);
    font-size: 12px;
    margin-left: 6px;
}

.to-line {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 2px;
}

.email-timestamp {
    font-size: 12px;
    color: var(--text-muted);
}

/* OTP HIGHLIGHT CARD */
.otp-highlight-card {
    background: linear-gradient(135deg, #e8f0fe 0%, #d2e3fc 100%);
    border: 1px solid #aecbfa;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.otp-badge-title {
    font-size: 14px;
    font-weight: 600;
    color: #174ea6;
}

.otp-number-display {
    font-size: 32px;
    font-weight: 800;
    letter-spacing: 6px;
    color: #1a73e8;
    background: #ffffff;
    padding: 6px 18px;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.copy-otp-btn {
    background-color: var(--primary-blue);
    color: #ffffff;
    border: none;
    padding: 10px 18px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.2s;
}

.copy-otp-btn:hover {
    background-color: var(--primary-blue-dark);
}

/* EMAIL CONTENT IFRAME */
.email-body-content {
    background: #ffffff;
    border-radius: 8px;
    min-height: 300px;
}

#email-sandbox-frame {
    width: 100%;
    min-height: 400px;
    border: none;
}

/* FOOTER */
.app-footer {
    padding: 24px 16px;
    text-align: center;
    border-top: 1px solid var(--border-subtle);
    background-color: var(--bg-surface);
    margin-top: auto;
}

.footer-links {
    font-size: 13px;
    margin-bottom: 8px;
}

.footer-links a {
    color: var(--primary-blue);
    text-decoration: none;
    margin: 0 4px;
}

.footer-links a:hover {
    text-decoration: underline;
}

.footer-copy {
    font-size: 12px;
    color: var(--text-muted);
}

/* MODAL */
.modal-overlay {
    position: fixed;
    top: 0; left: 0; right: 0; bottom: 0;
    background-color: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-card {
    background: #ffffff;
    border-radius: 16px;
    padding: 24px 28px;
    width: 100%;
    max-width: 440px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.modal-card h3 {
    font-size: 18px;
    margin-bottom: 8px;
    color: var(--text-primary);
}

.modal-card p {
    font-size: 13px;
    color: var(--text-muted);
    margin-bottom: 20px;
}

.custom-input-group {
    display: flex;
    align-items: center;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    overflow: hidden;
    margin-bottom: 24px;
}

.custom-input-group input {
    flex: 1;
    border: none;
    padding: 12px 14px;
    font-size: 14px;
    outline: none;
}

.domain-addon {
    background: var(--bg-page);
    padding: 12px 14px;
    font-size: 13px;
    color: var(--text-muted);
    border-left: 1px solid var(--border-color);
}

.modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}

.btn-secondary {
    background: none;
    border: 1px solid var(--border-color);
    padding: 8px 16px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    color: var(--text-secondary);
}

.btn-primary {
    background: var(--primary-blue);
    border: none;
    color: #ffffff;
    padding: 8px 18px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
}


/* TOAST SNACKBAR */
.toast-snackbar {
    position: fixed;
    bottom: 24px;
    left: 24px;
    background-color: #323232;
    color: #ffffff;
    padding: 12px 20px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    gap: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
    z-index: 2000;
    transform: translateY(100px);
    opacity: 0;
    transition: transform 0.3s ease, opacity 0.3s ease;
}

.toast-snackbar.show {
    transform: translateY(0);
    opacity: 1;
}

.toast-action {
    background: none;
    border: none;
    color: #a8c7fa;
    font-weight: 700;
    cursor: pointer;
    font-size: 13px;
    text-transform: uppercase;
}

/* --- SIDEBAR BACKDROP (MOBILE DRAWER) --- */
.sidebar-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.45);
    z-index: 998;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.sidebar-backdrop.show {
    opacity: 1;
    pointer-events: auto;
}

/* --- DESKTOP COLLAPSIBLE SIDEBAR --- */
@media (min-width: 769px) {
    .gmail-sidebar {
        transition: width 0.25s cubic-bezier(0.4, 0, 0.2, 1), padding 0.25s ease, opacity 0.2s ease;
    }
    .gmail-sidebar.collapsed {
        width: 0 !important;
        min-width: 0 !important;
        padding: 0 !important;
        margin: 0 !important;
        overflow: hidden !important;
        opacity: 0 !important;
        pointer-events: none !important;
    }
}

/* --- MOBILE RESPONSIVE (SMARTPHONES & TABLETS <= 768px) --- */
@media (max-width: 768px) {
    body.gmail-body {
        overflow-x: hidden;
        width: 100%;
    }

    /* HEADER */
    .gmail-header {
        height: auto;
        padding: 10px 12px;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        position: sticky;
        top: 0;
        background-color: var(--bg-page);
        border-bottom: 1px solid var(--border-subtle);
        z-index: 100;
    }

    .header-left {
        width: 100%;
        min-width: 0;
        display: flex;
        align-items: center;
        justify-content: flex-start;
        gap: 12px;
    }

    .brand-logo-img {
        height: 32px;
        max-width: 170px;
    }

    .header-center {
        width: 100%;
        max-width: 100%;
        margin: 0;
    }

    .header-right {
        display: none;
    }

    .email-search-bar {
        height: auto;
        min-height: 44px;
        padding: 10px 12px;
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        border-radius: 14px;
        background-color: #ffffff;
        box-shadow: 0 1px 3px rgba(0, 0, 0, 0.08);
    }

    .search-icon {
        display: none;
    }

    .current-email-wrapper {
        width: 100%;
        text-align: center;
        padding: 2px 0;
    }

    .active-email-text {
        font-size: 14px;
        word-break: break-all;
        white-space: normal;
        display: block;
        line-height: 1.4;
    }

    .email-action-pills {
        width: 100%;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 6px;
        flex-wrap: wrap;
    }

    .pill-action-btn {
        flex: 1 1 auto;
        justify-content: center;
        padding: 8px 10px;
        font-size: 12px;
    }

    .pill-action-btn.icon-only {
        flex: 0 0 auto;
        padding: 8px 10px;
    }

    /* APP CONTAINER & MAIN */
    .gmail-container {
        height: auto;
        min-height: calc(100vh - 120px);
        flex-direction: column;
        overflow: visible;
    }

    .gmail-main {
        margin: 0;
        border-radius: 0;
        box-shadow: none;
        height: auto;
        min-height: 450px;
        overflow: visible;
        width: 100%;
        max-width: 100vw;
    }

    .email-list-container {
        height: auto;
        overflow: visible;
    }

    /* OFF-CANVAS SIDEBAR DRAWER */
    .gmail-sidebar {
        position: fixed;
        top: 0;
        left: 0;
        bottom: 0;
        width: 280px;
        max-width: 82vw;
        height: 100vh;
        z-index: 1000;
        background-color: #ffffff;
        box-shadow: 4px 0 24px rgba(0, 0, 0, 0.25);
        transform: translateX(-100%);
        transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
        display: flex !important;
        flex-direction: column;
        padding: 20px 14px;
        overflow-y: auto;
    }

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

    /* EMPTY STATE & INSTRUCTIONS */
    .empty-inbox-state {
        padding: 32px 14px 20px 14px;
    }

    .empty-inbox-state h3 {
        font-size: 17px;
    }

    .empty-subtitle {
        font-size: 13px;
        margin-bottom: 20px;
    }

    .instructions-card {
        padding: 16px 12px;
        margin: 16px 0;
    }

    .step-item {
        gap: 12px;
        text-align: left;
    }

    .step-num {
        width: 26px;
        height: 26px;
        font-size: 12px;
        flex-shrink: 0;
    }

    /* MESSAGE ROWS */
    .msg-row {
        padding: 12px 10px;
        flex-wrap: wrap;
        gap: 4px 8px;
    }

    .msg-sender {
        width: auto;
        max-width: 150px;
        font-size: 13px;
    }

    .msg-date {
        margin-left: auto;
        font-size: 11px;
        width: auto;
    }

    .msg-content {
        width: 100%;
        flex-basis: 100%;
        padding-left: 28px;
        font-size: 12px;
    }

    .toolbar-right {
        display: none;
    }

    /* EMAIL DETAIL VIEW */
    .email-detail-container {
        padding: 10px 8px;
    }

    .email-detail-card {
        padding: 16px 12px;
    }

    .email-subject-title {
        font-size: 17px;
        line-height: 1.4;
    }

    .sender-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }

    .email-timestamp {
        margin-left: 0;
        font-size: 12px;
    }

    .otp-highlight-card {
        padding: 16px 12px;
    }

    .otp-number-display {
        font-size: 26px;
        letter-spacing: 4px;
    }

    /* SEO & FOOTER */
    .seo-knowledge-section {
        padding: 24px 14px 20px 14px;
    }

    .seo-knowledge-section h2 {
        font-size: 18px;
        margin: 22px 0 10px 0;
    }

    .feature-highlights-grid {
        grid-template-columns: 1fr;
        gap: 12px;
    }

    .feature-box {
        padding: 16px;
    }

    .app-footer {
        padding: 20px 12px;
    }

    .footer-links {
        display: flex;
        flex-wrap: wrap;
        justify-content: center;
        gap: 6px 12px;
        line-height: 1.6;
    }

    /* MODALS */
    .modal-card {
        width: 92%;
        max-width: 360px;
        padding: 20px 16px;
    }

    .custom-input-group {
        flex-direction: column;
        gap: 8px;
    }

    .domain-addon {
        border-radius: 8px;
        text-align: center;
        width: 100%;
    }
}


/* --- SEO KNOWLEDGE & AD SENSE SECTION --- */
.seo-knowledge-section {
    padding: 40px 24px 30px 24px;
    border-top: 1px solid var(--border-subtle);
    background-color: #fafbfc;
}

.seo-content-container {
    max-width: 900px;
    margin: 0 auto;
}

.seo-knowledge-section h2 {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin: 28px 0 14px 0;
    line-height: 1.4;
}

.seo-knowledge-section h2:first-child {
    margin-top: 0;
}

.seo-knowledge-section p {
    font-size: 14px;
    line-height: 1.8;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.seo-knowledge-section ul {
    margin: 12px 0 20px 24px;
    font-size: 14px;
    line-height: 1.8;
    color: var(--text-secondary);
}

.seo-knowledge-section li {
    margin-bottom: 6px;
}

.feature-highlights-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
    margin: 20px 0 28px 0;
}

.feature-box {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 10px;
    padding: 18px 20px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.04);
}

.feature-box h3 {
    font-size: 15px;
    font-weight: 700;
    color: var(--primary-blue);
    margin-bottom: 8px;
}

.feature-box p {
    font-size: 13px;
    line-height: 1.6;
    color: var(--text-muted);
    margin-bottom: 0;
}

.seo-faq-list {
    display: flex;
    flex-direction: column;
    gap: 12px;
    margin-top: 16px;
}

.seo-faq-item {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 16px 20px;
}

.seo-faq-item h3 {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 6px;
}

.seo-faq-item p {
    font-size: 13px;
    line-height: 1.65;
    color: var(--text-secondary);
    margin-bottom: 0;
}
