/* Home Page Layout & Hero Section */
.home-container {
    max-width: 1360px;
    margin: 0 auto;
    padding: 2.5rem 2rem 5rem;
}

.hero-section {
    padding: 5rem 1.5rem 4rem;
    text-align: center;
    position: relative;
    max-width: 900px;
    margin: 0 auto;
}

.hero-glow {
    position: absolute;
    top: 30%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 600px;
    height: 320px;
    background: radial-gradient(circle, var(--accent-glow) 0%, transparent 70%);
    filter: blur(80px);
    pointer-events: none;
    z-index: 0;
}

.hero-badge {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.45rem 1.3rem;
    border-radius: var(--radius-full);
    background: rgba(99, 102, 241, 0.12);
    color: var(--accent);
    font-size: 0.85rem;
    font-weight: 700;
    margin-bottom: 2rem;
    border: 1px solid rgba(99, 102, 241, 0.3);
    position: relative;
    z-index: 1;
}

[data-theme="dark"] .hero-badge,
:root:not([data-theme="light"]) .hero-badge {
    color: #a5b4fc;
}

[data-theme="light"] .hero-badge {
    background: rgba(99, 102, 241, 0.08);
    color: #4f46e5;
    border-color: rgba(99, 102, 241, 0.25);
}

.hero-title {
    font-size: 4.2rem;
    line-height: 1.1;
    margin-bottom: 1.5rem;
    position: relative;
    z-index: 1;
    font-weight: 800;
    letter-spacing: -0.04em;
    color: var(--heading-color);
}

[data-theme="dark"] .hero-title,
:root:not([data-theme="light"]) .hero-title {
    background: linear-gradient(135deg, #ffffff 0%, #cbd5e1 50%, #94a3b8 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

[data-theme="light"] .hero-title {
    color: #0f172a;
    -webkit-text-fill-color: initial;
    background: none;
}

.hero-subtitle {
    font-size: 1.2rem;
    color: var(--primary-dim);
    max-width: 680px;
    margin: 0 auto 2.8rem;
    position: relative;
    z-index: 1;
    line-height: 1.65;
}

.hero-cta-group {
    display: flex;
    gap: 1.2rem;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    position: relative;
    z-index: 1;
}

/* Feature & Portal Grid */
.portal-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 2rem;
    margin: 4rem auto 0;
    max-width: 1360px;
}

.portal-card {
    background: var(--bg-card);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: var(--radius-xl);
    padding: 2.8rem 2.4rem;
    text-decoration: none;
    color: inherit;
    transition: all var(--duration-normal) var(--ease-out);
    position: relative;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    box-shadow: var(--shadow-sm);
}

.portal-card:hover {
    transform: translateY(-6px);
    border-color: var(--accent);
    box-shadow: var(--shadow-lg);
}

.portal-icon {
    width: 58px;
    height: 58px;
    border-radius: 18px;
    background: var(--bg-glass);
    border: 1px solid var(--border-light);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.8rem;
    font-size: 1.8rem;
    color: var(--accent);
    transition: transform var(--duration-normal) ease;
}

.portal-card:hover .portal-icon {
    transform: scale(1.08);
    background: var(--accent-gradient);
    color: #ffffff;
    box-shadow: 0 0 16px var(--accent-glow);
}

.portal-card h3 {
    font-size: 1.55rem;
    margin-bottom: 0.8rem;
    color: var(--heading-color);
}

.portal-card p {
    color: var(--primary-dim);
    font-size: 0.94rem;
    line-height: 1.6;
    margin-bottom: 2rem;
}

.portal-link-label {
    font-size: 0.88rem;
    font-weight: 700;
    color: var(--accent);
    letter-spacing: 0.02em;
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    transition: color var(--duration-fast);
}

.portal-card:hover .portal-link-label {
    color: #818cf8;
}

/* Responsive Rules */
@media (max-width: 860px) {
    .home-container {
        padding: 1.5rem 1.25rem 4rem;
    }

    .hero-section {
        padding: 3rem 0.5rem 2.5rem;
    }

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

    .hero-subtitle {
        font-size: 1.05rem;
    }

    .portal-card {
        padding: 1.25rem 1rem;
    }
}