/* =========================
   FONT IMPORT
========================= */
@font-face {
    font-family: "Stickrice";
    src: url("../fonts/Stickrice-8jez.ttf") format("truetype");
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

/* =========================
   COLORS / TYPOGRAPHY
========================= */
:root {
    --text-xs: 22px;
    --text-sm: 24px;
    --text-md: 26px;
    --text-lg: 28px;
    --text-xl: 30px;
    --text-xxl: 40px;
    --main-color: #013758;
    --button-color: #e2e41a;
    --button-text-color: #080e40;
}

/* =========================
   RESET
========================= */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    text-align: center;
}

html,
body {
    width: 100%;
    min-height: 100%;
    overflow-x: hidden;
}

/* =========================
   BODY
========================= */
body {
    font-family: "Stickrice", 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: white;
    line-height: 1.5;
    font-size: var(--text-md);
    text-shadow: 2px 2px 3px rgba(0,0,0,0.85);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
    opacity: 0;
    animation: pageFadeIn 0.6s ease forwards;
}

/* =========================
   GLOBAL BACKGROUND 
========================= */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -2;
    pointer-events: none;
    background-image: url("../images/MO_Background1.png");
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
}

/* keep fade animation */
@keyframes pageFadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

/* =========================
   OPTIONAL LEGACY SYSTEM 
========================= */
.world-bg {
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;
    background-image: url("../images/MO_Background1.png");
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
}

/* =========================
   CONTAINER
========================= */
.container {
    width: min(1300px, 92%);
    margin: auto;
}

/* =========================
   NAVBAR
========================= */
.navbar {
    position: fixed;
    top: 0;
    width: 100%;
    background: var(--main-color);
    backdrop-filter: blur(10px);
    z-index: 1000;
}

.nav-inner {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 16px;
    flex-wrap: wrap;
    gap: 12px;
}

/* =========================
   LOGO
========================= */
.logo a {
    display: flex;
    align-items: center;
    gap: 6px;
    color: white;
    text-decoration: none;
}

.logo-icon {
    width: 64px;
    height: 64px;
}

/* =========================
   NAV LINKS
========================= */
.nav-links {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.nav-links a {
    display: flex;
    align-items: center;
    gap: 6px;
    color: white;
    text-decoration: none;
    font-size: var(--text-sm);
    opacity: 0.85;
    transition: 0.2s;
}

.nav-links a:hover {
    opacity: 1;
}

/* =========================
   NAV ICONS
========================= */
.nav-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
}

/* =========================
   BUTTONS
========================= */
.btn {
    padding: 12px 22px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 700;
    font-size: var(--text-md);
    display: inline-block;
    transition: 0.2s;
}

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

.primary,
.secondary {
    background: transparent;
    border: 2px solid var(--button-color);
    color: var(--button-color);
}

/* =========================
   HERO
========================= */
.hero {
    position: relative;
    height: 100vh;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    z-index: 1;
    isolation: isolate;
}

/* =========================
   HERO LAYERS
========================= */
.hero-layer {
    position: absolute;
    inset: 0;
    background-repeat: no-repeat;
    background-size: cover;
    background-position: center;
    pointer-events: none;
    will-change: transform;
}

/* SKY */
.layer-sky {
    z-index: 1;
    background-image: url("../images/hero/sky.png");
}

/* CLOUDS */
.layer-clouds {
    z-index: 2;
    background-image: url("../images/hero/clouds.png");
    opacity: 0.95;
    background-repeat: repeat-x;
    background-size: auto 100%;
    will-change: background-position;
    animation: cloudDrift 90s linear infinite;
}

@keyframes cloudDrift {
    from {
        background-position: 0 0;
    }

    to {
        background-position: 3000px 0;
    }
}

/* FAR BACK */
.layer-mountains-far {
    z-index: 3;
    background-image: url("../images/hero/mountains-far.png");
}

.layer-mountains-near {
    z-index: 4;
    background-image: url("../images/hero/mountains-near.png");
}

.layer-trees {
    z-index: 5;
    background-image: url("../images/hero/trees.png");
}

.layer-middle {
    z-index: 6;
    background-image: url("../images/hero/middle.png");
}

.layer-closesthill {
    z-index: 7;
    background-image: url("../images/hero/closesthill.png");
}

.layer-foreground {
    z-index: 8;
    background-image: url("../images/hero/foreground.png");
}

.hero-content {
    position: relative;
    z-index: 10;
    font-size: var(--text-xxl);
    color: white;
}

/* =========================
   SECTION
========================= */
.section {
    padding: 40px 0;
}

/* =========================
   CARD
========================= */
.card {
    background: rgba(255,255,255,0.05);
    padding: 24px;
    border-radius: 12px;
}

/* =========================
   NEWS WIDGET 
========================= */
.news-widget {
    width: min(900px, 92%);
    margin: 48px auto;
    padding: 48px;
    border-radius: 18px;
    position: relative;
    overflow: hidden;
    background-image: url("../images/universe newsbackground.png");
    background-size: cover;
    background-position: center;
    border: 1px solid rgba(255,255,255,0.18);
    box-shadow: 0 12px 40px rgba(0,0,0,0.65);
    color: white;
    display: grid;
    grid-template-columns: 340px 1fr;
    grid-template-rows: auto auto auto;
    column-gap: 30px;
    row-gap: 10px;
}

.news-widget::before {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(0,0,0,0.55);
    z-index: 0;
}

.news-widget > * {
    position: relative;
    z-index: 1;
}

/* =========================
   LEFT SIDE 
========================= */
.news-header {
    grid-column: 1;
    grid-row: 1;
    display: flex;
    align-items: center;
    gap: 10px;
    justify-content: flex-start;
    margin-left: 10px;
}

.news-icon {
    font-size: 18px;
}

.news-title {
    font-size: 18px;
    font-weight: bold;
    letter-spacing: 2px;
}

.news-image {
    grid-column: 1;
    grid-row: 2 / span 2;
    width: 320px;
    height: 320px;
    margin-top: 30px;
    overflow: hidden;
    border-radius: 12px;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

/* =========================
   RIGHT SIDE 
========================= */
.news-headline {
    grid-column: 2;
    grid-row: 1;
    font-size: 40px;
    font-weight: bold;
    text-align: center;
    transform: translateX(-16px);
}

.news-text {
    grid-column: 2;
    grid-row: 2;
    font-size: 20px;
    line-height: 1.6;
    opacity: 0.95;
    max-width: 600px;
    margin: 12px auto 0;
    text-align: center;
    transform: translateX(-16px);
}

/* =========================
   DOTS 
========================= */
.news-dots {
    grid-column: 1 / span 2;
    display: flex;
    justify-content: flex-start;
    gap: 10px;
    margin-top: auto;
    padding-top: 30px;
    padding-left: 360px;
}

.news-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255,255,255,0.35);
    cursor: pointer;
    transition: 0.25s ease;
    border: 1px solid rgba(255,255,255,0.15);
}

.news-dot.active {
    background: var(--button-color);
    transform: scale(1.4);
}

/* =========================
   CLASS PAGE LAYOUT 
========================= */
.class-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    flex-wrap: wrap;
}

.class-row.reverse {
    flex-direction: row-reverse;
}

.class-text {
    flex: 1;
    text-align: left;
}

.class-text h2 {
    margin-bottom: 12px;
}

.class-text p {
    text-align: left;
}

.class-image {
    flex: 1;
    text-align: center;
}

.class-image img {
    max-width: 420px;
    width: 100%;
    height: auto;
}