/* CSS variables for consistent theming */
:root {
    --bg-color: #08080a;
    --card-bg: rgba(15, 15, 20, 0.7);
    --card-border: rgba(255, 255, 255, 0.08);
    --text-primary: #f4f4f7;
    --text-secondary: #a1a1aa;
    --accent-orange: #ff9900;
    --accent-gold: #ffaa00;
    --accent-red: #ff5500;
    --primary-grad: linear-gradient(135deg, var(--accent-orange) 0%, var(--accent-red) 100%);
    --card-hover-bg: rgba(25, 25, 35, 0.85);
    --card-hover-border: rgba(255, 153, 0, 0.3);
    --font-heading: 'Outfit', sans-serif;
    --font-body: 'Plus Jakarta Sans', sans-serif;
    --transition-smooth: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset and base styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    background-color: var(--bg-color);
    color: var(--text-primary);
    font-family: var(--font-body);
    min-height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    overflow-x: hidden;
    position: relative;
    padding: 2rem 1rem;
    line-height: 1.5;
}

/* Ambient glow spheres */
.glow-sphere {
    position: absolute;
    border-radius: 50%;
    filter: blur(100px);
    z-index: 1;
    pointer-events: none;
    opacity: 0.6;
}

.glow-1 {
    width: 400px;
    height: 400px;
    background: radial-gradient(circle, rgba(255, 153, 0, 0.15) 0%, rgba(255, 85, 0, 0) 70%);
    top: -100px;
    left: -100px;
    animation: floating-glow 15s infinite alternate ease-in-out;
}

.glow-2 {
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(0, 242, 254, 0.1) 0%, rgba(79, 172, 254, 0) 70%);
    bottom: -150px;
    right: -100px;
    animation: floating-glow-reverse 20s infinite alternate ease-in-out;
}

@keyframes floating-glow {
    0% { transform: translate(0, 0) scale(1); }
    100% { transform: translate(80px, 50px) scale(1.1); }
}

@keyframes floating-glow-reverse {
    0% { transform: translate(0, 0) scale(1.1); }
    100% { transform: translate(-80px, -50px) scale(0.9); }
}

/* Main Container */
.container {
    width: 100%;
    max-width: 680px;
    z-index: 2;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

/* Hub Card */
.hub-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-radius: 24px;
    padding: 2.5rem;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

/* Header Section */
.header {
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.75rem;
}

.brand-badge {
    background: rgba(255, 153, 0, 0.1);
    border: 1px solid rgba(255, 153, 0, 0.2);
    color: var(--accent-orange);
    padding: 0.35rem 1rem;
    border-radius: 99px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.5rem;
}

.amazon-icon {
    animation: pulse 2s infinite ease-in-out;
}

@keyframes pulse {
    0%, 100% { opacity: 0.8; }
    50% { opacity: 1; filter: drop-shadow(0 0 4px var(--accent-orange)); }
}

.title {
    font-family: var(--font-heading);
    font-size: 2.25rem;
    font-weight: 800;
    background: linear-gradient(135deg, #ffffff 50%, var(--text-secondary) 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    letter-spacing: -0.02em;
}

.subtitle {
    color: var(--text-secondary);
    font-size: 0.975rem;
    max-width: 500px;
    line-height: 1.6;
}

.subtitle strong {
    color: var(--text-primary);
}

/* Referral Box */
.referral-box {
    background: rgba(0, 0, 0, 0.2);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    position: relative;
    overflow: hidden;
}

.referral-box::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--primary-grad);
}

.code-label {
    font-size: 0.75rem;
    font-weight: 700;
    color: var(--text-secondary);
    letter-spacing: 0.1em;
}

.code-wrapper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 320px;
    gap: 1rem;
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid rgba(255, 255, 255, 0.05);
    padding: 0.5rem 0.5rem 0.5rem 1.25rem;
    border-radius: 12px;
}

.code-text {
    font-family: monospace;
    font-size: 1.5rem;
    font-weight: 700;
    letter-spacing: 0.05em;
    color: #ffffff;
    text-shadow: 0 0 10px rgba(255, 153, 0, 0.2);
}

.copy-btn {
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    font-family: var(--font-body);
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 0.4rem;
    transition: var(--transition-smooth);
}

.copy-btn:hover {
    background: var(--text-primary);
    color: var(--bg-color);
    border-color: var(--text-primary);
    transform: translateY(-1px);
}

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

/* Primary CTA Button */
.primary-cta {
    background: var(--primary-grad);
    color: #ffffff;
    text-decoration: none;
    padding: 1rem 2rem;
    border-radius: 14px;
    font-weight: 700;
    font-size: 1.05rem;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    box-shadow: 0 8px 24px rgba(255, 153, 0, 0.3);
    transition: var(--transition-smooth);
    border: none;
    cursor: pointer;
}

.primary-cta:hover {
    box-shadow: 0 12px 32px rgba(255, 153, 0, 0.45);
    transform: translateY(-2px);
}

.primary-cta:active {
    transform: translateY(1px);
}

/* Categories Section */
.categories-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.section-title {
    font-family: var(--font-heading);
    font-size: 1.2rem;
    font-weight: 700;
    letter-spacing: -0.01em;
    color: var(--text-primary);
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

.category-card {
    background: rgba(255, 255, 255, 0.02);
    border: 1px solid var(--card-border);
    border-radius: 16px;
    padding: 1.25rem;
    text-decoration: none;
    color: var(--text-primary);
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
    transition: var(--transition-smooth);
}

.category-card:hover {
    background: var(--card-hover-bg);
    border-color: var(--card-hover-border);
    transform: translateY(-3px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
}

.category-card.highlight {
    background: linear-gradient(135deg, rgba(255, 153, 0, 0.05) 0%, rgba(255, 85, 0, 0.02) 100%);
    border-color: rgba(255, 153, 0, 0.15);
}

.category-card.highlight:hover {
    background: linear-gradient(135deg, rgba(255, 153, 0, 0.12) 0%, rgba(255, 85, 0, 0.05) 100%);
    border-color: var(--accent-orange);
}

.category-icon {
    width: 42px;
    height: 42px;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
    transition: var(--transition-smooth);
}

.category-card:hover .category-icon {
    background: rgba(255, 153, 0, 0.15);
    color: var(--accent-orange);
}

.category-name {
    font-weight: 600;
    font-size: 0.95rem;
}

/* Guide Section */
.guide-section {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.guide-steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
}

.step-card {
    background: rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(255, 255, 255, 0.03);
    border-radius: 14px;
    padding: 1.25rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.step-number {
    width: 28px;
    height: 28px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    color: var(--text-secondary);
    font-weight: 700;
    font-size: 0.85rem;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.step-card h3 {
    font-size: 0.95rem;
    font-weight: 700;
}

.step-card p {
    font-size: 0.8rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

/* Footer styling */
.footer {
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.35);
    padding: 1rem 0;
}

.footer-link {
    color: rgba(255, 255, 255, 0.55);
    text-decoration: none;
    transition: var(--transition-smooth);
    border-bottom: 1px dotted rgba(255, 255, 255, 0.3);
}

.footer-link:hover {
    color: var(--accent-orange);
    border-color: var(--accent-orange);
}

/* Success Copy Toast Alert */
.toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translate(-50%, 100px);
    background: #0f172a;
    border: 1px solid rgba(255, 153, 0, 0.2);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    padding: 0.85rem 1.5rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    z-index: 999;
    font-weight: 600;
    font-size: 0.9rem;
    opacity: 0;
    visibility: hidden;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.3s ease, visibility 0.3s ease;
}

.toast.show {
    transform: translate(-50%, 0);
    opacity: 1;
    visibility: visible;
}

.toast-check {
    color: #10b981;
}

/* Responsiveness adjustments */
@media (max-width: 640px) {
    .hub-card {
        padding: 1.75rem;
        gap: 1.5rem;
    }
    
    .title {
        font-size: 1.75rem;
    }
    
    .categories-grid {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .guide-steps {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }
    
    .step-card {
        flex-direction: row;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .step-card h3 {
        margin-top: 0.15rem;
    }
    
    .step-text-wrapper {
        display: flex;
        flex-direction: column;
        gap: 0.25rem;
    }
}
