/* style.css - Complete */
:root {
    --bg-dark: #0b1020;
    --bg-deep: #11162a;
    --surface: rgba(255, 255, 255, 0.92);
    --surface-soft: rgba(255, 255, 255, 0.72);
    --surface-border: rgba(255, 255, 255, 0.18);
    --text-primary: #171a2b;
    --text-secondary: #5b6078;
    --text-muted: #7a8098;
    --white: #ffffff;
    --primary: #7c3aed;
    --primary-2: #ec4899;
    --primary-3: #a855f7;
    --success: #10b981;
    --danger: #ef4444;
    --shadow-lg: 0 20px 60px rgba(11, 16, 32, 0.18);
    --shadow-md: 0 12px 35px rgba(17, 24, 39, 0.12);
    --radius-xl: 24px;
    --radius-lg: 18px;
    --radius-md: 14px;
    --container: 1200px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    color: var(--text-primary);
    background:
        radial-gradient(circle at top left, rgba(168, 85, 247, 0.28), transparent 28%),
        radial-gradient(circle at top right, rgba(236, 72, 153, 0.20), transparent 25%),
        linear-gradient(180deg, #f8f5ff 0%, #fff7fc 45%, #f6f8ff 100%);
    min-height: 100vh;
    line-height: 1.6;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font: inherit;
}

.container {
    width: min(var(--container), calc(100% - 32px));
    margin: 0 auto;
}

/* Navbar */
.navbar {
    position: sticky;
    top: 0;
    z-index: 1000;
    backdrop-filter: blur(18px);
    background: rgba(255, 255, 255, 0.78);
    border-bottom: 1px solid rgba(124, 58, 237, 0.08);
}

.nav-container {
    min-height: 78px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 20px;
}

.nav-brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.logo-badge {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    color: var(--white);
    font-size: 20px;
    box-shadow: 0 10px 24px rgba(168, 85, 247, 0.28);
}

.brand-name {
    display: block;
    font-weight: 800;
    font-size: 1rem;
    letter-spacing: -0.02em;
}

.brand-subtitle {
    display: block;
    font-size: 0.76rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.nav-links {
    display: flex;
    align-items: center;
    gap: 10px;
}

.nav-links a {
    padding: 10px 14px;
    border-radius: 12px;
    color: var(--text-secondary);
    font-weight: 600;
    transition: 0.25s ease;
}

.nav-links a:hover,
.nav-links a.active {
    color: var(--primary);
    background: rgba(124, 58, 237, 0.08);
}

/* Hero Section */
.hero {
    padding: 84px 0 48px;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 0.9fr;
    gap: 34px;
    align-items: center;
}

.hero-home {
    padding-top: 72px;
}

.eyebrow,
.section-kicker,
.card-kicker {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    font-size: 0.78rem;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    font-weight: 700;
    color: var(--primary);
    margin-bottom: 14px;
}

.eyebrow.light,
.section-kicker.light {
    color: rgba(255, 255, 255, 0.88);
}

.hero-title {
    font-size: clamp(2.4rem, 5vw, 4.4rem);
    line-height: 1.08;
    letter-spacing: -0.04em;
    font-weight: 800;
    margin-bottom: 18px;
}

.gradient-text {
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.hero-description,
.section-description,
.tempmail-hero p,
.support-hero p {
    font-size: 1.05rem;
    color: var(--text-secondary);
    max-width: 680px;
}

.hero-buttons {
    margin-top: 28px;
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.hero-mini-stats {
    margin-top: 34px;
    display: flex;
    gap: 14px;
    flex-wrap: wrap;
}

.mini-stat {
    min-width: 120px;
    padding: 16px 18px;
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(124, 58, 237, 0.08);
    box-shadow: var(--shadow-md);
}

.mini-stat strong {
    display: block;
    font-size: 1.1rem;
    color: var(--text-primary);
}

.mini-stat span {
    color: var(--text-muted);
    font-size: 0.92rem;
}

/* Cards */
.glass-card,
.premium-card {
    background: var(--surface);
    border: 1px solid var(--surface-border);
    backdrop-filter: blur(14px);
    box-shadow: var(--shadow-lg);
    border-radius: var(--radius-xl);
}

.hero-preview-card {
    padding: 24px;
}

.preview-top {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 22px;
}

.dot-group {
    display: flex;
    gap: 8px;
}

.dot-group span {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    opacity: 0.8;
}

.preview-label {
    font-size: 0.86rem;
    color: var(--text-muted);
    font-weight: 600;
}

.preview-email-box {
    padding: 18px;
    border-radius: 18px;
    background: rgba(124, 58, 237, 0.05);
    margin-bottom: 18px;
}

.preview-email-box label {
    display: block;
    font-size: 0.86rem;
    color: var(--text-muted);
    margin-bottom: 8px;
}

.preview-input {
    padding: 14px 16px;
    border-radius: 14px;
    background: var(--white);
    border: 1px solid rgba(124, 58, 237, 0.12);
    font-weight: 600;
    color: var(--text-primary);
}

.preview-message-list {
    display: grid;
    gap: 12px;
}

.preview-message {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    padding: 16px;
    border-radius: 16px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(124, 58, 237, 0.08);
}

.preview-message strong {
    font-size: 0.94rem;
}

.preview-message p {
    font-size: 0.88rem;
    color: var(--text-muted);
    margin-top: 2px;
}

.preview-message span {
    color: var(--text-muted);
    font-size: 0.82rem;
    white-space: nowrap;
}

/* Sections */
.section {
    padding: 82px 0;
}

.surface-light {
    background: rgba(255, 255, 255, 0.72);
    border-top: 1px solid rgba(124, 58, 237, 0.06);
    border-bottom: 1px solid rgba(124, 58, 237, 0.06);
}

.section-heading {
    text-align: center;
    max-width: 760px;
    margin: 0 auto 44px;
}

.section-title {
    font-size: clamp(1.9rem, 4vw, 3rem);
    letter-spacing: -0.03em;
    line-height: 1.14;
    margin-bottom: 12px;
}

/* Features & FAQ Grids */
.features-grid,
.faq-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.feature-card,
.faq-card {
    padding: 28px;
}

.feature-icon {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.6rem;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.12), rgba(236, 72, 153, 0.12));
    margin-bottom: 18px;
}

.feature-card h3,
.faq-card h3,
.contact-card h3,
.step-card h3,
.generator-card h2,
.inbox-header h2 {
    font-size: 1.18rem;
    margin-bottom: 10px;
    letter-spacing: -0.02em;
}

.feature-card p,
.faq-card p,
.contact-card p,
.step-card p,
.tips-box li,
.empty-state p {
    color: var(--text-secondary);
}

/* Steps */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 22px;
}

.step-card {
    padding: 30px;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 68px;
    height: 40px;
    padding: 0 16px;
    border-radius: 999px;
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    color: var(--white);
    font-weight: 700;
    margin-bottom: 18px;
    box-shadow: 0 12px 28px rgba(168, 85, 247, 0.26);
}

/* CTA */
.cta-section {
    padding-top: 18px;
}

.cta-card {
    text-align: center;
    padding: 48px 28px;
    border-radius: 32px;
    color: var(--white);
    background: linear-gradient(135deg, #5b21b6, #db2777);
    box-shadow: 0 26px 60px rgba(91, 33, 182, 0.22);
}

.cta-card h2 {
    font-size: clamp(1.8rem, 4vw, 2.8rem);
    margin-bottom: 12px;
    letter-spacing: -0.03em;
}

.cta-card p {
    margin-bottom: 24px;
    color: rgba(255, 255, 255, 0.86);
}

/* Footer */
.footer {
    background: #0d1020;
    color: rgba(255, 255, 255, 0.68);
    padding-top: 52px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 1.2fr 0.8fr 0.8fr;
    gap: 26px;
}

.footer h4 {
    color: var(--white);
    margin-bottom: 12px;
    font-size: 1rem;
}

.footer p,
.footer a {
    color: rgba(255, 255, 255, 0.68);
}

.footer ul {
    list-style: none;
}

.footer li + li {
    margin-top: 8px;
}

.footer a:hover {
    color: var(--white);
}

.footer-bottom {
    padding: 24px 0;
    margin-top: 30px;
    border-top: 1px solid rgba(255, 255, 255, 0.08);
    text-align: center;
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 48px;
    padding: 0 18px;
    border: none;
    cursor: pointer;
    border-radius: 14px;
    font-weight: 700;
    transition: 0.25s ease;
}

.btn:hover {
    transform: translateY(-1px);
}

.btn-primary {
    color: var(--white);
    background: linear-gradient(135deg, var(--primary), var(--primary-2));
    box-shadow: 0 14px 32px rgba(168, 85, 247, 0.28);
}

.btn-secondary {
    color: var(--primary);
    background: rgba(124, 58, 237, 0.08);
    border: 1px solid rgba(124, 58, 237, 0.12);
}

.btn-secondary:hover {
    background: rgba(124, 58, 237, 0.12);
}

.btn-white {
    background: var(--white);
    color: var(--primary);
}

.btn-accent {
    color: var(--white);
    background: linear-gradient(135deg, #8b5cf6, #ec4899);
}

.btn-small {
    min-height: 42px;
    padding: 0 14px;
    font-size: 0.95rem;
}

.btn-full {
    width: 100%;
}

.btn-danger {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

.btn-danger:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 20px rgba(239, 68, 68, 0.3);
}

/* Button Group */
.button-group {
    display: flex;
    gap: 12px;
    margin-bottom: 20px;
}

.button-group .btn {
    flex: 1;
}

/* Tempmail */
.main-tempmail {
    padding: 42px 0 80px;
}

.tempmail-hero {
    margin-bottom: 26px;
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 18px;
}

.tempmail-hero h1 {
    font-size: clamp(2rem, 4vw, 3.1rem);
    line-height: 1.1;
    letter-spacing: -0.03em;
    margin-bottom: 10px;
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    background: rgba(255, 255, 255, 0.74);
    border: 1px solid rgba(124, 58, 237, 0.1);
    padding: 12px 16px;
    border-radius: 999px;
    color: var(--text-secondary);
    white-space: nowrap;
}

.status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: var(--success);
    box-shadow: 0 0 0 6px rgba(16, 185, 129, 0.14);
}

.tempmail-layout {
    display: grid;
    grid-template-columns: 400px 1fr;
    gap: 24px;
    align-items: start;
}

.generator-card,
.inbox-section {
    padding: 26px;
}

/* Input Groups */
.input-group {
    margin-bottom: 18px;
}

.input-group label,
.email-result label {
    display: block;
    margin-bottom: 8px;
    font-size: 0.92rem;
    font-weight: 700;
    color: var(--text-primary);
}

.input-control {
    width: 100%;
    min-height: 52px;
    padding: 0 16px;
    border-radius: 14px;
    border: 1px solid rgba(124, 58, 237, 0.14);
    background: rgba(255, 255, 255, 0.94);
    color: var(--text-primary);
    outline: none;
    transition: 0.2s ease;
}

.input-control:focus {
    border-color: rgba(124, 58, 237, 0.42);
    box-shadow: 0 0 0 4px rgba(168, 85, 247, 0.1);
}

/* Email Display */
.email-result {
    margin-top: 18px;
}

.modern-display {
    display: flex;
    gap: 10px;
}

.modern-display input {
    flex: 1;
    min-height: 52px;
    padding: 0 16px;
    border-radius: 14px;
    border: 1px solid rgba(124, 58, 237, 0.12);
    background: #f8f7ff;
    color: var(--text-primary);
    font-weight: 500;
}

.modern-display button#openInboxBtn {
    min-width: 52px;
    font-size: 1.2rem;
    font-weight: 600;
}

/* Valid/Invalid Email Styling */
.input-control.invalid-email {
    border-color: #ef4444;
    background: rgba(239, 68, 68, 0.05);
}

.input-control.valid-email {
    border-color: #10b981;
    background: rgba(16, 185, 129, 0.05);
}

/* Tips Box */
.tips-box {
    margin-top: 22px;
    padding: 18px;
    border-radius: 18px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.06), rgba(236, 72, 153, 0.06));
    border: 1px solid rgba(124, 58, 237, 0.08);
}

.tips-box h3 {
    font-size: 1rem;
    margin-bottom: 10px;
}

.tips-box ul {
    padding-left: 18px;
}

/* Inbox */
.inbox-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
    margin-bottom: 18px;
}

.inbox-actions {
    display: flex;
    gap: 10px;
}

.modern-email-list {
    min-height: 500px;
    max-height: 650px;
    overflow-y: auto;
    padding-right: 6px;
}

/* Email Items */
.email-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 18px;
    border-radius: 18px;
    border: 1px solid rgba(124, 58, 237, 0.08);
    background: rgba(255, 255, 255, 0.88);
    transition: 0.2s ease;
}

.email-item + .email-item {
    margin-top: 12px;
}

.email-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 12px 30px rgba(17, 24, 39, 0.08);
    border-color: rgba(124, 58, 237, 0.18);
}

.email-content {
    flex: 1;
    cursor: pointer;
}

.email-top {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 8px;
}

.email-from {
    font-weight: 700;
    color: var(--text-primary);
    word-break: break-word;
}

.email-date {
    font-size: 0.78rem;
    color: var(--text-muted);
    white-space: nowrap;
}

.email-subject {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin-bottom: 6px;
    word-break: break-word;
}

.email-snippet {
    font-size: 0.88rem;
    color: var(--text-muted);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

/* Delete Email Button */
.delete-email-btn {
    background: rgba(239, 68, 68, 0.1);
    border: none;
    cursor: pointer;
    padding: 6px 10px;
    border-radius: 10px;
    font-size: 1rem;
    transition: 0.2s ease;
    color: #ef4444;
}

.delete-email-btn:hover {
    background: rgba(239, 68, 68, 0.2);
    transform: scale(1.05);
}

/* Empty & Loading States */
.empty-state,
.loading {
    min-height: 320px;
    display: grid;
    place-items: center;
    text-align: center;
    padding: 32px 16px;
    border-radius: 20px;
    border: 1px dashed rgba(124, 58, 237, 0.18);
    background: rgba(124, 58, 237, 0.03);
}

.empty-icon {
    font-size: 2rem;
    margin-bottom: 12px;
}

.empty-state h3 {
    margin-bottom: 8px;
}

.loading {
    color: var(--primary);
    font-weight: 700;
}

.hidden {
    display: none !important;
}

/* Detail Modal */
.email-detail {
    position: fixed;
    inset: 0;
    z-index: 2000;
}

.detail-overlay {
    position: absolute;
    inset: 0;
    background: rgba(11, 16, 32, 0.55);
    backdrop-filter: blur(6px);
}

.detail-panel {
    position: absolute;
    top: 0;
    right: 0;
    width: min(760px, 100%);
    height: 100%;
    background: #ffffff;
    box-shadow: -24px 0 50px rgba(11, 16, 32, 0.22);
    padding: 24px;
    display: flex;
    flex-direction: column;
    overflow: hidden;
    transform: translateX(100%);
    transition: transform 0.28s ease;
}

.email-detail.show .detail-panel {
    transform: translateX(0);
}

.detail-header {
    display: flex;
    align-items: start;
    justify-content: space-between;
    gap: 16px;
    padding-bottom: 16px;
    border-bottom: 1px solid rgba(124, 58, 237, 0.12);
}

.detail-header h3 {
    font-size: 1.35rem;
    line-height: 1.3;
    letter-spacing: -0.02em;
}

.close-btn {
    width: 42px;
    height: 42px;
    border-radius: 14px;
    border: none;
    cursor: pointer;
    background: rgba(239, 68, 68, 0.1);
    color: var(--danger);
    font-size: 1rem;
    font-weight: 700;
}

.detail-meta {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 14px;
    margin: 18px 0;
}

.meta-card {
    padding: 14px 16px;
    border-radius: 16px;
    background: #f8f7ff;
    border: 1px solid rgba(124, 58, 237, 0.08);
}

.meta-label {
    display: block;
    font-size: 0.78rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    font-weight: 700;
    color: var(--text-muted);
    margin-bottom: 6px;
}

.detail-actions {
    margin: 16px 0;
    display: flex;
    justify-content: flex-end;
}

.detail-content-wrapper {
    flex: 1;
    overflow: auto;
    border-radius: 18px;
    background: #fafbff;
    border: 1px solid rgba(124, 58, 237, 0.08);
    padding: 18px;
}

.detail-content {
    color: var(--text-primary);
    line-height: 1.75;
    word-break: break-word;
}

.detail-content iframe,
.detail-content img {
    max-width: 100%;
}

/* Support Page */
.premium-hero {
    padding: 82px 0 72px;
    text-align: center;
    color: var(--white);
    background:
        radial-gradient(circle at left top, rgba(255,255,255,0.12), transparent 24%),
        linear-gradient(135deg, #5b21b6, #db2777);
}

.premium-hero h1 {
    font-size: clamp(2rem, 4vw, 3.4rem);
    letter-spacing: -0.04em;
    margin-bottom: 10px;
}

.premium-hero p {
    color: rgba(255, 255, 255, 0.84);
    margin: 0 auto;
}

.premium-contact-card {
    max-width: 620px;
    margin: 0 auto;
    padding: 38px 28px;
    text-align: center;
}

.contact-badge {
    width: 72px;
    height: 72px;
    border-radius: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 2rem;
    margin-bottom: 16px;
    background: linear-gradient(135deg, rgba(124, 58, 237, 0.14), rgba(236, 72, 153, 0.14));
}

/* Responsive Design */
@media (max-width: 1024px) {
    .hero-grid,
    .tempmail-layout,
    .features-grid,
    .faq-grid,
    .steps-grid,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .tempmail-layout {
        gap: 18px;
    }

    .detail-meta {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 768px) {
    .nav-container {
        min-height: auto;
        padding: 14px 0;
        flex-direction: column;
        align-items: stretch;
    }

    .nav-brand {
        justify-content: center;
    }

    .nav-links {
        justify-content: center;
        flex-wrap: wrap;
    }

    .hero,
    .section,
    .premium-hero {
        padding-top: 56px;
        padding-bottom: 56px;
    }

    .hero-buttons,
    .hero-mini-stats,
    .modern-display,
    .tempmail-hero,
    .inbox-header {
        flex-direction: column;
        align-items: stretch;
    }

    .status-pill {
        width: fit-content;
    }

    .generator-card,
    .inbox-section,
    .hero-preview-card,
    .step-card,
    .feature-card,
    .faq-card {
        padding: 22px;
    }

    .detail-panel {
        width: 100%;
        padding: 18px;
    }

    .section-heading {
        margin-bottom: 28px;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .inbox-actions {
        flex-direction: column;
    }
}

@media (max-width: 520px) {
    .container {
        width: min(100% - 20px, var(--container));
    }

    .hero-title {
        font-size: 2.2rem;
    }

    .section-title,
    .tempmail-hero h1,
    .premium-hero h1 {
        font-size: 1.8rem;
    }

    .mini-stat {
        min-width: 100%;
    }

    .btn {
        width: 100%;
    }
}
