/*
 * MAGHEL Website
 * Version: 1.0.0
 * Main Stylesheet
 *
 * Design: Dark Cosmic / Blue & Gold
 * Languages: UK / RU / EN
 */

/* ==========================================
   1. Design Tokens
   ========================================== */

:root {
    --background: #050c19;
    --surface: #0b1c31;
    --surface-light: #142b47;

    --gold: #d5af78;
    --white: #f1f3f7;
    --muted: #a4b2c6;

    --border: rgba(213, 175, 120, 0.28);
}

/* ==========================================
   2. Base Styles
   ========================================== */

* {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: 76px;
}

body {
    margin: 0;
    min-width: 320px;
    overflow-x: hidden;

    font-family: Georgia, "Times New Roman", serif;
    line-height: 1.65;

    background: var(--background);
    color: var(--white);
}


body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;

    background-image: url("/assets/images/directions-bg.webp");

    background-position: center center;
    background-size: cover;
    background-repeat: no-repeat;
}

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

button {
    font: inherit;
    cursor: pointer;
}

.container {
    width: min(1160px, 92%);
    margin: 0 auto;
}

.center {
    text-align: center;
}

.muted {
    color: var(--muted);
}

.gold {
    color: var(--gold);
}

/* ==========================================
   3. Shared Typography
   ========================================== */

.eyebrow {
    color: var(--gold);
    font-size: 0.75rem;
    letter-spacing: 0.25em;
    text-transform: uppercase;
}

.section {
    padding: 90px 0;
}

.section-title {
    margin: 14px 0 24px;

    color: #efdfc8;
    font-size: clamp(2rem, 4vw, 3.3rem);
    font-weight: 400;
    line-height: 1.2;
}

.section-description {
    max-width: 670px;
    margin: 0 auto 42px;

    color: var(--muted);
}

/* ==========================================
   4. Header
   ========================================== */

.site-header {
    position: sticky;
    top: 0;
    z-index: 100;

    background: linear-gradient(
        180deg,
        rgba(3, 9, 22, 0.98) 0%,
        rgba(3, 9, 22, 0.88) 45%,
        rgba(3, 9, 22, 0.62) 80%,
        rgba(3, 9, 22, 0.35) 100%
    );

    border-bottom: 1px solid rgba(213, 175, 120, 0.12);

    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);

    transform: translateY(0);

    transition:
        transform 0.75s cubic-bezier(0.22, 1, 0.36, 1),
        box-shadow 0.5s ease;

    will-change: transform;
}

.site-header.header-hidden {
    transform: translateY(-100%);
}

@media (prefers-reduced-motion: reduce) {
    .site-header {
        transition: none;
    }
}


.header-inner {
    display: flex;
    align-items: center;
    justify-content: space-between;

    min-height: 76px;
    gap: 20px;
}

.brand {
    display: inline-flex;
    align-items: center;
    flex-shrink: 0;

    white-space: nowrap;
}

.brand-logo {
    display: block;
    width: auto;
    height: 42px;
    object-fit: contain;
}

.navigation {
    display: flex;
    align-items: center;
    gap: 19px;

    color: #d7e1ee;
    font: 13px Arial, sans-serif;
}

.navigation a:hover,
.footer-links a:hover {
    color: var(--gold);
}

.navigation a.nav-active,
.mobile-links a.nav-active {
    color: #f4d49c;
    text-shadow: 0 0 14px rgba(244, 212, 156, 0.55);
}

/* ==========================================
   5. Language Switcher
   ========================================== */

.language-switcher {
    display: flex;
    align-items: center;
    flex-shrink: 0;
    gap: 5px;
}

.language-switcher button {
    padding: 6px 7px;

    color: #91a5bb;
    background: transparent;
    border: 1px solid transparent;
    border-radius: 4px;

    font: 12px Arial, sans-serif;
}

.language-switcher button.active,
.language-switcher button[aria-pressed="true"] {
    color: var(--gold);
    background: rgba(213, 175, 120, 0.08);
    border-color: var(--border);
}

/* ==========================================
   6. Mobile Navigation
   ========================================== */

.mobile-menu {
    display: none;
}

/* ==========================================
   7. Hero Background
   ========================================== */

.hero {
    position: relative;
    display: flex;
    align-items: center;
    overflow: hidden;

    min-height: 680px;

    background-image:
        linear-gradient(
            90deg,
            rgba(2, 7, 17, 0.24) 0%,
            rgba(2, 7, 17, 0.12) 48%,
            rgba(2, 7, 17, 0.02) 100%
        ),
        url("/assets/images/hero-v4.webp");

    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;

    border-bottom: 1px solid var(--border);
}


/* ==========================================
   8. Hero Content
   ========================================== */

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

    padding: 35px 0;
    padding-left: clamp(180px, 15vw, 260px);

    text-align: center;
}

.hero-content .eyebrow {
    display: inline-block;
    margin-bottom: 10px;
    padding: 7px 14px;

    color: #f2ddba;
    background: rgba(4, 11, 24, 0.42);
    border: 1px solid rgba(213, 175, 120, 0.20);
    border-radius: 999px;
    backdrop-filter: blur(6px);

    text-shadow:
        0 1px 2px rgba(0, 0, 0, 0.72),
        0 0 10px rgba(0, 0, 0, 0.38);

    box-shadow:
        0 0 18px rgba(3, 10, 22, 0.20);
}

.hero-logo-title {
    margin: 0 0 5px;
    padding: 0;
    line-height: 1;
}

.hero-logo {
    display: block;
    width: min(100%, 650px);
    height: auto;
    margin: 0 auto;

    filter:
        drop-shadow(
            0 0 12px rgba(255, 196, 105, 0.35)
        )
        drop-shadow(
            0 0 28px rgba(50, 145, 255, 0.20)
        );
}

.hero-content h2 {
    max-width: 650px;
    margin: 0 auto 12px;

    font-size: clamp(1.6rem, 3vw, 2.6rem);
    font-weight: 400;
    line-height: 1.3;
}

.hero-content p {
    width: fit-content;
    max-width: 620px;
    margin: 0 auto;
    padding: 8px 18px;

    color: #f1f5fa;
    background: rgba(4, 11, 24, 0.38);
    border: none;
    border-radius: 8px;

    backdrop-filter: blur(5px);

    font-size: 0.95rem;
    line-height: 1.65;

    text-shadow:
        0 1px 3px rgba(0, 0, 0, 0.85),
        0 0 10px rgba(0, 0, 0, 0.35);
}


/* ==========================================
   9. Buttons
   ========================================== */

.actions {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-top: 30px;
}

.hero-content .actions {
    justify-content: center;
    margin-top: 24px;
}

.button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    isolation: isolate;

    min-height: 50px;
    padding: 13px 28px;

    color: #21170c;
    background: linear-gradient(
        165deg,
        #fff0ba 0%,
        #e8bd74 25%,
        #bb803b 64%,
        #f4d594 100%
    );

    border: 1px solid #f3d599;
    border-radius: 7px;

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.85),
        inset 0 -2px 3px rgba(91, 45, 10, 0.30),
        0 3px 12px rgba(0, 0, 0, 0.28),
        0 0 16px rgba(231, 171, 84, 0.25);

    font: 600 14px Arial, sans-serif;
    text-align: center;
    text-shadow: 0 1px 0 rgba(255, 240, 203, 0.40);

    cursor: pointer;

    transition:
        transform 0.25s ease,
        box-shadow 0.25s ease,
        filter 0.25s ease;
}

.button::before {
    content: "";
    position: absolute;
    inset: 1px 2px auto;
    z-index: -1;
    height: 42%;

    background: linear-gradient(
        180deg,
        rgba(255, 255, 255, 0.38),
        transparent
    );

    border-radius: 5px 5px 50% 50%;
    pointer-events: none;
}

.button:hover {
    transform: translateY(-3px);
    filter: brightness(1.08);

    box-shadow:
        inset 0 1px 0 rgba(255, 255, 255, 0.95),
        inset 0 -2px 3px rgba(91, 45, 10, 0.30),
        0 6px 20px rgba(0, 0, 0, 0.35),
        0 0 25px rgba(255, 194, 92, 0.65),
        0 0 45px rgba(255, 194, 92, 0.20);
}

.button:active {
    transform: translateY(0);
}

.button:focus-visible {
    outline: 2px solid #ffffff;
    outline-offset: 4px;
}

/* Secondary button */

.button.outline {
    color: #f5ddb2;

    background: linear-gradient(
        160deg,
        rgba(18, 46, 77, 0.94),
        rgba(3, 11, 25, 0.96)
    );

    border: 1px solid #d7a763;

    box-shadow:
        inset 0 1px 0 rgba(245, 213, 160, 0.28),
        inset 0 0 12px rgba(40, 117, 189, 0.18),
        0 3px 12px rgba(0, 0, 0, 0.32),
        0 0 12px rgba(213, 175, 120, 0.16);

    text-shadow: 0 0 8px rgba(255, 220, 165, 0.30);
}

.button.outline::before {
    background: linear-gradient(
        180deg,
        rgba(127, 189, 244, 0.16),
        transparent
    );
}

.button.outline:hover {
    filter: brightness(1.12);

    box-shadow:
        inset 0 1px 0 rgba(245, 213, 160, 0.45),
        0 6px 20px rgba(0, 0, 0, 0.35),
        0 0 22px rgba(213, 175, 120, 0.45),
        0 0 35px rgba(42, 133, 216, 0.18);
}



/* ==========================================
   Directions Section
   ========================================== */

#directions {
    position: relative;
    z-index: 2;
    overflow: hidden;

    margin-top: -160px;
    padding-top: 210px;

    background-image:
        linear-gradient(
            180deg,
            rgba(3, 10, 24, 0.10) 0%,
            rgba(3, 10, 24, 0.20) 60%,
            rgba(3, 10, 24, 0.35) 100%
        ),
        url("/assets/images/directions-bg.webp");

    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;

    -webkit-mask-image: linear-gradient(
        to bottom,
        transparent 0,
        #000 160px
    );

    mask-image: linear-gradient(
        to bottom,
        transparent 0,
        #000 160px
    );
}


/* ==========================================
   Directions Cards
   ========================================== */

#directions .grid {
    align-items: stretch;
    gap: 28px;
}

#directions .card {
    display: flex;
    flex-direction: column;
    align-items: center;
    overflow: hidden;

    min-height: 0px;
    padding: 0 0 24px;

    background: linear-gradient(
        180deg,
        rgba(10, 30, 53, 0.97),
        rgba(3, 12, 26, 0.96)
    );

    border: 1px solid rgba(231, 182, 109, 0.75);
    border-radius: 18px;

    box-shadow:
        inset 0 0 18px rgba(47, 123, 189, 0.12),
        0 8px 30px rgba(0, 0, 0, 0.35),
        0 0 16px rgba(231, 182, 109, 0.10);

    text-align: center;

    transition:
        transform 0.3s ease,
        border-color 0.3s ease,
        box-shadow 0.3s ease;
}

#directions .card::before {
    content: "";
    display: block;
    flex-shrink: 0;

    width: 100%;
    aspect-ratio: 16 / 10;

    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;

    border-bottom: 1px solid rgba(231, 182, 109, 0.45);
}

#directions .card:nth-child(1)::before {
    background-image: url("/assets/images/tarot.webp");
}

#directions .card:nth-child(2)::before {
    background-image: url("/assets/images/runes.webp");
}

#directions .card:nth-child(3)::before {
    background-image: url("/assets/images/chronicles.webp");
}

#directions .card-icon {
    display: none;
}

#directions .card h3 {
    margin: 20px 16px 12px;

    color: #f4d49c;
    font-size: 1.85rem;
    font-weight: 400;
    line-height: 1.3;

    text-shadow:
        0 0 12px rgba(234, 177, 91, 0.30);
}

#directions .card p {
    flex-grow: 0;

    margin: 0 0 16px;
    padding: 0 22px;

    color: #d8e2ef;
    font-size: 0.95rem;
    line-height: 1.65;
}

#directions .card-note {
    margin-top: auto;
    padding: 9px 18px;

    color: #ebcb93;
    background: rgba(213, 175, 120, 0.08);

    border: 1px solid rgba(213, 175, 120, 0.30);
    border-radius: 6px;

    font-size: 0.85rem;
}

#directions .card:hover {
    transform: translateY(-7px);

    border-color: #ffe2a4;

    box-shadow:
        inset 0 0 24px rgba(255, 204, 120, 0.12),
        inset 0 0 40px rgba(44, 140, 255, 0.10),
        0 16px 40px rgba(0, 0, 0, 0.45),
        0 0 12px rgba(255, 210, 126, 0.85),
        0 0 30px rgba(255, 183, 76, 0.55),
        0 0 60px rgba(35, 137, 255, 0.35);
}

@media (prefers-reduced-motion: reduce) {
    #directions .card {
        transition: none;
    }
}


/* ==========================================
   10. Content Grid
   ========================================== */

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

/* ==========================================
   11. Cards
   ========================================== */

.card {
    min-height: 240px;
    padding: 32px 25px;

    background: linear-gradient(
        150deg,
        rgba(22, 50, 82, 0.69),
        rgba(7, 19, 36, 0.92)
    );

    border: 1px solid var(--border);
    border-radius: 12px;

    transition:
        transform 0.2s ease,
        border-color 0.2s ease;
}

.card:hover {
    transform: translateY(-4px);
    border-color: var(--gold);
}

.card-icon {
    margin-bottom: 14px;

    color: var(--gold);
    font-size: 2.8rem;
}

.card h3 {
    margin: 0 0 10px;

    color: #f1ddb9;
    font-size: 1.55rem;
}

.card p {
    color: var(--muted);
    font-size: 0.95rem;
}

.card-note {
    color: var(--gold);
    font-size: 0.85rem;
}

/* ==========================================
   12. About Section
   ========================================== */

.about-section {
    background: linear-gradient(
        90deg,
        rgba(6, 16, 30, 0.79),
        rgba(23, 50, 75, 0.38),
        rgba(6, 16, 30, 0.79)
    );

    border-block: 1px solid var(--border);
}

.quote {
    max-width: 840px;
    margin: 25px auto;

    color: #e9e3dc;
    font-size: clamp(1.3rem, 2.7vw, 2rem);
    font-style: italic;
    white-space: pre-line;
}

.about-section .actions {
    justify-content: center;
    margin-top: 28px;
}

/* ==========================================
   13. Practices Section
   ========================================== */

.services {
    grid-template-columns: repeat(4, 1fr);
}

.services .card {
    min-height: 200px;
    padding: 25px 20px;
}

.services .card h3 {
    font-size: 1.25rem;
}

/* ==========================================
   14. Contact Section
   ========================================== */

.contact-section {
    padding: 95px 0;

    background: radial-gradient(
        ellipse at center,
        rgba(22, 68, 109, 0.53),
        transparent 65%
    );
}

.contact-symbol {
    color: var(--gold);
    font-size: 5rem;
    line-height: 1;

    text-shadow: 0 0 35px rgba(217, 174, 130, 0.48);
}

/* ==========================================
   15. Footer
   ========================================== */

.site-footer {
    background: rgba(2, 7, 17, 0.94);
    border-top: 1px solid var(--border);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 35px;

    padding: 64px 0 45px;
}

.site-footer h3 {
    color: var(--gold);
    font-size: 1.1rem;
    font-weight: 400;
}

.footer-links {
    display: grid;
    gap: 11px;
}

.footer-links a,
.footer-links span {
    color: #aebfd1;
    font: 13px/1.5 Arial, sans-serif;
}

.footer-bottom {
    padding: 25px 0 35px;

    color: #91a3b7;
    border-top: 1px solid var(--border);

    font: 12px/1.8 Arial, sans-serif;
    text-align: center;
}

/* ==========================================
   16. Tablet Layout
   ========================================== */

@media (max-width: 1000px) {
    .navigation {
        display: none;
    }

    .mobile-menu {
        position: relative;
        display: block;
    }

    .mobile-menu summary {
        color: var(--gold);
        cursor: pointer;
        font: 14px Arial, sans-serif;
    }

    .mobile-links {
        position: absolute;
        top: 38px;
        right: 0;
        z-index: 30;

        display: grid;
        width: 220px;
        gap: 14px;
        padding: 22px;

        background: #08182c;
        border: 1px solid var(--border);
        border-radius: 8px;

        font: 14px Arial, sans-serif;
    }

    .grid,
    .services {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* ==========================================
   17. Small Tablet Layout
   ========================================== */

@media (max-width: 900px) {
    .hero-content {
        padding-left: 0;
        text-align: center;
    }
}

/* ==========================================
   18. Mobile Layout
   ========================================== */

@media (max-width: 600px) {
    .header-inner {
        gap: 12px;
    }

    .brand-logo {
        height: 34px;
    }

    .language-switcher button {
        padding: 5px;
    }

    .hero {
        min-height: 620px;
    }

    .hero-content {
        padding: 75px 0;
    }

    .hero-logo {
        width: 90%;
        max-width: 420px;
    }

    .section {
        padding: 65px 0;
    }

    .grid,
    .services,
    .footer-grid {
        grid-template-columns: 1fr;
    }

    .card {
        min-height: auto;
    }

    .footer-grid {
        gap: 24px;
    }
}

/* ==========================================
   19. Reduced Motion
   ========================================== */

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }

    .button,
    .card {
        transition: none;
    }
}



/* ==========================================
   20. About Mage Page
   ========================================== */

body.about-body {
    background: #04101f;
}

body.about-body::before {
    content: "";
    position: fixed;
    inset: 0;
    z-index: -1;
    pointer-events: none;

    background-image:
        linear-gradient(
            90deg,
            rgba(3, 10, 24, 0.08) 0%,
            rgba(3, 10, 24, 0.30) 50%,
            rgba(3, 10, 24, 0.55) 100%
        ),
        url("/assets/images/helheim-bg.webp");

    background-position: center;
    background-size: cover;
    background-repeat: no-repeat;
}

.about-page {
    display: flex;
    align-items: center;

    min-height: 0;
    padding: 55px 0 65px;

    background: none;
    border-bottom: 1px solid rgba(213, 175, 120, 0.20);
}

.about-page .container {
    display: flex;
    flex-direction: column;
    align-items: center;
}

.about-page .eyebrow,
.about-page .section-title,
.about-page .section-description {
    width: 100%;
    text-align: center;
}

.about-page .section-title {
    margin: 12px 0 20px;
}

.about-page .section-description {
    margin: 0;

    color: #e4e9f1;
    font-size: 1.1rem;
    line-height: 1.8;
}

@media (max-width: 900px) {
    .about-page {
        padding: 75px 0;
    }

    .about-page .container {
        align-items: center;
    }

    .about-page .eyebrow,
    .about-page .section-title,
    .about-page .section-description {
        width: 100%;
    }
}


/* ==========================================
   21. Mage Story Sections
   ========================================== */

.mage-section {
    position: relative;
    padding: 45px 0;
    background: transparent;
}


.mage-section {
    position: relative;
    padding: 24px 0;
    background: transparent;
}

.mage-content {
    width: min(960px, 92%);
    margin: 0 auto;
}

.mage-content .section-title {
    margin-bottom: 20px;
    color: #f2dbb5;
    font-size: clamp(2rem, 3.5vw, 2.8rem);
}

.mage-content p {
    margin: 0 0 14px;

    color: #e5edf6;
    font-size: 1.18rem;
    line-height: 1.75;
}

.mage-identity,
.mage-knowledge,
.mage-practices,
.mage-free-will,
.mage-exchange {
    border-bottom: 1px solid rgba(213, 175, 120, 0.16);
}

.mage-identity .mage-content,
.mage-knowledge .mage-content,
.mage-practices .mage-content,
.mage-free-will .mage-content,
.mage-exchange .mage-content {
  padding: 40px 46px;
  background: linear-gradient(
    145deg,
    rgba(4, 13, 29, 0.50),
    rgba(7, 24, 45, 0.34)
  );
  border: 1px solid rgba(213, 175, 120, 0.10);
  border-radius: 14px;
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  box-shadow: 0 12px 36px rgba(0, 0, 0, 0.14);
}


/* ==========================================
   22. Highlighted Mage Statements
   ========================================== */

.mage-highlight {
    position: relative;

    margin: 24px 0 8px;
    padding: 18px 24px;

    color: #f4d9aa;
    background: linear-gradient(
        90deg,
        rgba(213, 175, 120, 0.10),
        rgba(213, 175, 120, 0.02)
    );

    border-left: 3px solid #d5af78;
    border-radius: 0 8px 8px 0;

    font-size: 1.18rem;
    font-style: italic;
    line-height: 1.8;

    text-shadow: 0 0 15px rgba(213, 175, 120, 0.18);
}

/* ==========================================
   23. Light and Dark Forces
   ========================================== */

.mage-forces {
    margin-top: 26px;
    padding-top: 22px;

    border-top: 1px solid rgba(213, 175, 120, 0.30);
}

.mage-forces h3 {
    margin: 0 0 18px;

    color: #ead0a4;
    font-size: clamp(1.5rem, 3vw, 2rem);
    font-weight: 400;
    line-height: 1.35;
}

/* ==========================================
   24. Mage Practice List
   ========================================== */

.mage-practice-list {
    display: grid;
    gap: 0;
}

.mage-practice {
    padding: 16px 0;

    border-bottom: 1px solid rgba(213, 175, 120, 0.18);
}

.mage-practice:first-child {
    padding-top: 0;
}

.mage-practice:last-child {
    border-bottom: none;
}

.mage-practice h3 {
    margin: 0 0 10px;

    color: #e9c88f;
    font-size: 1.35rem;
    font-weight: 400;
}

.mage-practice p {
    margin: 0;
}

.mage-conclusion {
    margin-top: 35px !important;
    color: #f2dbb5 !important;
    font-style: italic;
}

/* ==========================================
   25. Mage Final Word
   ========================================== */

.mage-final {
    padding: 55px 0 70px;

    background: radial-gradient(
        ellipse at center,
        rgba(15, 54, 94, 0.40),
        transparent 72%
    );
}

.mage-final .mage-content {
    max-width: 760px;
    text-align: center;
}

.mage-final .eyebrow {
    margin-bottom: 15px;
}

.mage-final .section-title {
    margin-bottom: 24px;
}

.mage-final .mage-highlight {
    margin: 35px auto;
    padding: 24px 30px;

    border-left: none;
    border-top: 1px solid #d5af78;
    border-bottom: 1px solid #d5af78;
    border-radius: 0;

    text-align: center;
}

.mage-final .mage-signature {
    margin-top: 45px;

    color: #e9c88f;
    font-size: 1.6rem;
    letter-spacing: 0.22em;

    text-shadow: 0 0 22px rgba(213, 175, 120, 0.35);
}

.mage-final .mage-tagline {
    color: #b8c9db;
    font-style: italic;
}

.mage-actions {
    justify-content: center;
    margin-top: 35px;
}

/* ==========================================
   26. Mage Page Responsive Layout
   ========================================== */

@media (max-width: 600px) {
    .mage-section {
        padding: 55px 0;
    }

    .mage-content {
        width: 92%;
    }

    .mage-identity .mage-content,
    .mage-knowledge .mage-content,
    .mage-practices .mage-content,
    .mage-free-will .mage-content,
    .mage-exchange .mage-content {
        padding: 28px 22px;
    }

    .mage-content p {
        font-size: 1rem;
        line-height: 1.8;
    }

    .mage-highlight {
        margin-top: 28px;
        padding: 20px;

        font-size: 1.06rem;
    }

    .mage-final {
        padding: 75px 0 85px;
    }
}
