@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&display=swap');

:root {
    --bg-dark: #121214;
    --card-bg: #1a1a1d;
    --card-border: #27272a;
    --card-hover-border: #3f3f46;
    
    --text-primary: #ffffff;
    --text-secondary: #a1a1aa;
    
    --accent-blue: #007AFF;
    --accent-blue-hover: #0056b3;
    --icon-box-bg: rgba(0, 122, 255, 0.12);
    
    --font-main: 'Inter', sans-serif;
}

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

body {
    background-color: var(--bg-dark);
    color: var(--text-primary);
    font-family: var(--font-main);
    line-height: 1.5;
    min-height: 100vh;
    /* Dot pattern background */
    background-image: radial-gradient(rgba(255, 255, 255, 0.05) 1px, transparent 1px);
    background-size: 24px 24px;
    background-position: center;
}

/* ================= ANIMATIONS ================= */
@keyframes fadeDown {
    from { opacity: 0; transform: translateY(-20px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}
@keyframes fadeRight {
    from { opacity: 0; transform: translateX(-30px); }
    to { opacity: 1; transform: translateX(0); }
}
@keyframes scaleUp {
    from { opacity: 0; transform: translate(-50%, -50%) scale(0.85); }
    to { opacity: 0.8; transform: translate(-50%, -50%) scale(1); }
}
@keyframes appear {
    from { opacity: 0; transform: translateY(20px) scale(0.98); }
    to { opacity: 1; transform: translateY(0) scale(1); }
}

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

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 40px;
}

/* ================= HEADER ================= */
header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 24px 0;
    border-bottom: 1px solid rgba(255,255,255,0.05);
}

.logo-container {
    display: flex;
    align-items: center;
    gap: 16px;
    animation: fadeDown 0.6s ease-out backwards;
}
.logo-header {
    display: flex;
    align-items: center;
    font-weight: 800;
    font-size: 1.1rem;
    letter-spacing: 0.5px;
    position: relative;
}
.logo-text-top {
    position: relative;
    z-index: 2;
}
.logo-header i {
    color: var(--accent-blue);
    font-size: 1.4rem;
}
.graphic-star-small {
    width: 32px;
    height: 32px;
    margin-left: -14px;
    margin-right: 4px;
    position: relative;
    z-index: 1;
    filter: drop-shadow(0 2px 4px rgba(0, 122, 255, 0.4));
    transform: rotate(15deg);
}
.logo-header span.wiki-text {
    color: var(--text-secondary);
    font-weight: 400;
    position: relative;
    z-index: 2;
}
.header-credits {
    font-size: 0.65rem;
    color: var(--text-secondary);
    letter-spacing: 0.5px;
    font-weight: 500;
    margin-top: 4px;
}
.header-credits a {
    color: var(--accent-blue);
    font-weight: 700;
    text-transform: uppercase;
    transition: color 0.2s;
}
.header-credits a:hover {
    color: var(--text-primary);
}

.search-container {
    position: relative;
    width: 400px;
    animation: fadeDown 0.6s ease-out 0.1s backwards;
}
.search-container i {
    position: absolute;
    left: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: var(--text-secondary);
}
.search-container input {
    width: 100%;
    background: #18181b;
    border: 1px solid var(--card-border);
    border-radius: 6px;
    padding: 10px 14px 10px 40px;
    color: var(--text-primary);
    font-family: var(--font-main);
    font-size: 0.9rem;
    outline: none;
    transition: 0.2s;
}
.search-container input:focus {
    border-color: var(--accent-blue);
}
.search-shortcut {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    background: #27272a;
    padding: 2px 6px;
    border-radius: 4px;
    font-size: 0.7rem;
    color: var(--text-secondary);
    border: 1px solid #3f3f46;
}

.header-actions {
    display: flex;
    gap: 16px;
    animation: fadeDown 0.6s ease-out 0.2s backwards;
}
.header-actions button {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.2rem;
    cursor: pointer;
    transition: 0.2s;
}
.header-actions button:hover {
    color: var(--text-primary);
}

/* ================= HERO SECTION ================= */
.hero-section {
    position: relative;
    text-align: center;
    padding: 100px 0 80px;
    overflow: hidden;
}

.hero-bg-text {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 320px;
    font-weight: 900;
    color: transparent;
    -webkit-text-stroke: 2px rgba(255, 255, 255, 0.03);
    z-index: -1;
    pointer-events: none;
    user-select: none;
    animation: scaleUp 1.2s cubic-bezier(0.16, 1, 0.3, 1) backwards;
}

.hero-content {
    position: relative;
    z-index: 1;
}

.hero-subtitle {
    color: var(--accent-blue);
    font-size: 0.75rem;
    font-weight: 700;
    letter-spacing: 4px;
    text-transform: uppercase;
    margin-bottom: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    animation: fadeUp 0.6s ease-out 0.3s backwards;
}
.hero-subtitle::before, .hero-subtitle::after {
    content: '';
    height: 1px;
    width: 40px;
    background: var(--accent-blue);
}

.hero-title {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 4rem;
    font-weight: 900;
    margin-bottom: 16px;
    letter-spacing: -1px;
    position: relative;
    animation: fadeUp 0.6s ease-out 0.4s backwards;
}
.logo-text-hero {
    position: relative;
    z-index: 2;
}
.graphic-star-large {
    width: 130px;
    height: 130px;
    margin-left: -50px;
    margin-right: -15px;
    position: relative;
    z-index: 1;
    transform: rotate(15deg);
    animation: starPulse 4s infinite alternate ease-in-out;
}
@keyframes starPulse {
    0% { transform: rotate(15deg); }
    100% { transform: rotate(15deg) scale(1.05); filter: brightness(1.2); }
}

.hero-desc {
    color: var(--text-secondary);
    font-size: 1rem;
    max-width: 500px;
    margin: 0 auto 40px;
    animation: fadeUp 0.6s ease-out 0.5s backwards;
}

.btn-primary {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: var(--accent-blue);
    color: #fff;
    padding: 14px 28px;
    border-radius: 4px;
    font-weight: 600;
    font-size: 0.95rem;
    transition: 0.2s;
    border: none;
    cursor: pointer;
    animation: fadeUp 0.6s ease-out 0.6s backwards;
}
.btn-primary:hover {
    background-color: var(--accent-blue-hover);
}

/* ================= SECTIONS ================= */
.section {
    margin-bottom: 60px;
}

.section-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 24px;
    animation: fadeRight 0.6s ease-out 0.7s backwards;
}
.section-num {
    color: var(--accent-blue);
    font-weight: 800;
    font-size: 1.2rem;
}
.section-title {
    font-size: 0.9rem;
    font-weight: 700;
    letter-spacing: 1.5px;
    text-transform: uppercase;
}

/* ================= GRID 4 COLS ================= */
.grid-4 {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 4px;
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 16px;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    animation: appear 0.6s cubic-bezier(0.16, 1, 0.3, 1) backwards;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}
.card > * { position: relative; z-index: 2; }

/* The Shine / Sweep effect */
.card::after, .card-wide::after {
    content: '';
    position: absolute;
    top: 0; left: -150%;
    width: 50%; height: 100%;
    background: linear-gradient(to right, rgba(255,255,255,0) 0%, rgba(255,255,255,0.08) 50%, rgba(255,255,255,0) 100%);
    transform: skewX(-25deg);
    transition: all 0.7s ease;
    z-index: 1; pointer-events: none;
}
.card:hover::after, .card-wide:hover::after {
    left: 150%;
    transition: all 0.7s ease;
}

/* The Spotlight effect */
.card::before, .card-wide::before {
    content: '';
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: radial-gradient(400px circle at var(--mouse-x, 0) var(--mouse-y, 0), rgba(0, 122, 255, 0.15), transparent 40%);
    opacity: 0;
    transition: opacity 0.4s;
    z-index: 0; pointer-events: none;
    border-radius: inherit;
}
.card:hover::before, .card-wide:hover::before {
    opacity: 1;
}

.card:hover {
    border-color: var(--accent-blue);
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 15px 35px -5px rgba(0, 122, 255, 0.25), 0 0 20px rgba(0, 122, 255, 0.1) inset;
    background: #19191e;
}

.card-icon {
    width: 48px;
    height: 48px;
    background: var(--icon-box-bg);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-blue);
    font-size: 1.4rem;
    flex-shrink: 0;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.card:hover .card-icon {
    background: var(--accent-blue);
    color: #fff;
    transform: scale(1.15) rotate(-10deg);
    box-shadow: 0 5px 15px rgba(0, 122, 255, 0.4);
}

.card-content h3 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 4px;
    color: var(--text-primary);
}
.card-content p {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* ================= GRID 2 COLS ================= */
.grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.card-wide {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 4px;
    padding: 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.4s cubic-bezier(0.25, 0.8, 0.25, 1);
    animation: appear 0.6s cubic-bezier(0.16, 1, 0.3, 1) backwards;
    cursor: pointer;
    position: relative;
    overflow: hidden;
}
.card-wide > * { position: relative; z-index: 2; }
.card-wide:hover {
    border-color: var(--accent-blue);
    transform: translateY(-6px) scale(1.02);
    box-shadow: 0 15px 35px -5px rgba(0, 122, 255, 0.25), 0 0 20px rgba(0, 122, 255, 0.1) inset;
    background: #19191e;
}

.card-wide-left {
    display: flex;
    align-items: center;
    gap: 20px;
}
.card-wide-icon {
    width: 56px;
    height: 56px;
    background: var(--icon-box-bg);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--accent-blue);
    font-size: 1.6rem;
    flex-shrink: 0;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.card-wide:hover .card-wide-icon {
    background: var(--accent-blue);
    color: #fff;
    transform: scale(1.15) rotate(-10deg);
    box-shadow: 0 5px 15px rgba(0, 122, 255, 0.4);
}
.card-wide-content h3 {
    font-size: 1.05rem;
    font-weight: 600;
    margin-bottom: 6px;
}
.card-stats {
    display: flex;
    align-items: center;
    gap: 16px;
    font-size: 0.75rem;
    color: var(--text-secondary);
}
.card-stats span {
    display: flex;
    align-items: center;
    gap: 6px;
}

.card-arrow {
    color: var(--text-secondary);
    font-size: 1.2rem;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
}
.card-wide:hover .card-arrow {
    transform: translateX(12px) scale(1.2);
    color: var(--accent-blue);
}

/* NEWS SECTION STYLING (Adapted to new design) */
#newsContainer {
    display: flex;
    flex-direction: column;
    gap: 16px;
    margin-top: 16px;
}
.news-item {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 4px;
    padding: 24px;
}
.news-date {
    color: var(--accent-blue);
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 8px;
    display: block;
}
.news-item h2 {
    font-size: 1.2rem;
    margin-bottom: 16px;
}
.news-text {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 16px;
}
.news-media img, .news-media video {
    max-width: 100%;
    border-radius: 4px;
    border: 1px solid var(--card-border);
}

footer {
    text-align: center;
    padding: 40px 0;
    color: var(--text-secondary);
    font-size: 0.8rem;
    border-top: 1px solid rgba(255,255,255,0.05);
    margin-top: 60px;
}

/* ================= RESPONSIVE ================= */
@media (max-width: 1024px) {
    .grid-4 {
        grid-template-columns: repeat(2, 1fr);
    }
    .hero-bg-text {
        font-size: 200px;
    }
}
@media (max-width: 768px) {
    .grid-2 {
        grid-template-columns: 1fr;
    }
    .hero-title {
        font-size: 3rem;
    }
    .hero-bg-text {
        font-size: 150px;
    }
    .search-container {
        display: none; /* Hide on mobile for simplicity, or make it collapsible */
    }
}
@media (max-width: 480px) {
    .grid-4 {
        grid-template-columns: 1fr;
    }
    .hero-bg-text {
        display: none;
    }
}
