:root {
    color-scheme: light;
    --mdg-bg: #151126;
    --mdg-accent: #f5c451;
    --mdg-play: #66d1c5;
    --mdg-ink: #1d1930;
    --mdg-muted: #686273;
    --mdg-paper: #faf8f3;
    --mdg-paper-strong: #ffffff;
    --mdg-line: #e4dfd5;
    --mdg-purple: #2c2247;
    --mdg-coral: #ec6681;
    --mdg-radius: 1.1rem;
    --mdg-shadow: 0 1.2rem 3rem rgba(13, 9, 28, 0.14);
    --mdg-width: 74rem;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    min-width: 20rem;
    margin: 0;
    color: var(--mdg-ink);
    background:
        radial-gradient(circle at 12% 8%, color-mix(in srgb, var(--mdg-play) 12%, transparent), transparent 28rem),
        var(--mdg-bg);
    font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
    font-size: 1rem;
    line-height: 1.65;
    text-rendering: optimizeLegibility;
}

body.menu-is-open {
    overflow: hidden;
}

img,
svg,
video {
    display: block;
    max-width: 100%;
}

a {
    color: #4b367c;
    text-decoration-thickness: 0.08em;
    text-underline-offset: 0.18em;
}

a:hover {
    color: #2c1d51;
}

button,
input,
select,
textarea {
    font: inherit;
}

:focus-visible {
    outline: 0.2rem solid var(--mdg-play);
    outline-offset: 0.2rem;
}

.skip-link {
    position: fixed;
    z-index: 1000;
    top: 0.75rem;
    left: 0.75rem;
    padding: 0.7rem 1rem;
    color: var(--mdg-ink);
    background: var(--mdg-accent);
    border-radius: 0.65rem;
    font-weight: 800;
    transform: translateY(-150%);
    transition: transform 160ms ease;
}

.skip-link:focus {
    color: var(--mdg-ink);
    transform: translateY(0);
}

.site-header {
    position: relative;
    z-index: 20;
    color: #fff;
    background: color-mix(in srgb, var(--mdg-bg) 90%, transparent);
    border-bottom: 1px solid rgba(255, 255, 255, 0.11);
    backdrop-filter: blur(1rem);
}

.header-inner,
.hero-inner,
.breadcrumbs-wrap,
.main-shell,
.module-band,
.footer-inner {
    width: min(calc(100% - 2rem), var(--mdg-width));
    margin-inline: auto;
}

.header-inner {
    min-height: 5rem;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 2rem;
}

.brand {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    min-width: 0;
    color: #fff;
    text-decoration: none;
}

.brand:hover {
    color: #fff;
}

.brand-logo {
    width: auto;
    max-width: min(17rem, 58vw);
    height: 3.3rem;
    object-fit: contain;
}

.brand-mark {
    display: grid;
    grid-template-columns: repeat(2, 1.35rem);
    grid-template-rows: repeat(2, 1.35rem);
    gap: 0.18rem;
    flex: 0 0 auto;
    transform: rotate(-5deg);
}

.brand-mark span {
    display: grid;
    place-items: center;
    color: var(--mdg-ink);
    background: var(--mdg-accent);
    border-radius: 0.28rem;
    font-size: 0.72rem;
    font-weight: 900;
    line-height: 1;
    box-shadow: 0.18rem 0.18rem 0 rgba(0, 0, 0, 0.2);
}

.brand-mark span:nth-child(2) {
    color: var(--mdg-bg);
    background: var(--mdg-play);
}

.brand-mark span:nth-child(3) {
    grid-column: 2;
    color: #fff;
    background: var(--mdg-coral);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    min-width: 0;
    line-height: 1.12;
}

.brand-copy strong {
    overflow: hidden;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(1.1rem, 2vw, 1.4rem);
    letter-spacing: 0.01em;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.brand-copy small {
    margin-top: 0.24rem;
    color: rgba(255, 255, 255, 0.66);
    font-size: 0.76rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    text-transform: uppercase;
}

.site-navigation .mod-menu {
    display: flex;
    align-items: center;
    gap: 0.25rem;
    margin: 0;
    padding: 0;
    list-style: none !important;
}

.site-navigation .mod-menu li {
    position: relative;
    display: block;
    margin: 0;
    padding: 0;
    list-style: none !important;
}

.site-navigation .mod-menu li::marker {
    content: "";
}

.site-navigation .mod-menu a,
.site-navigation .mod-menu .nav-header,
.site-navigation .mod-menu .separator {
    display: inline-flex;
    align-items: center;
    min-height: 2.75rem;
    padding: 0.55rem 0.85rem;
    color: rgba(255, 255, 255, 0.82);
    border-radius: 0.7rem;
    font-size: 0.95rem;
    font-weight: 750;
    text-decoration: none;
}

.site-navigation .mod-menu a:hover,
.site-navigation .mod-menu a:focus-visible,
.site-navigation .mod-menu .active > a,
.site-navigation .mod-menu .current > a {
    color: #fff;
    background: rgba(255, 255, 255, 0.1);
}

.site-navigation .mod-menu > .active > a::after,
.site-navigation .mod-menu > .current > a::after {
    position: absolute;
    right: 0.85rem;
    bottom: 0.28rem;
    left: 0.85rem;
    height: 0.16rem;
    content: "";
    background: var(--mdg-accent);
    border-radius: 999px;
}

.site-navigation .mod-menu li > ul {
    position: absolute;
    z-index: 25;
    top: calc(100% + 0.35rem);
    left: 0;
    display: none;
    flex-direction: column;
    align-items: stretch;
    gap: 0.15rem;
    min-width: 13rem;
    margin: 0;
    padding: 0.45rem;
    background: #241b3c;
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 0.8rem;
    box-shadow: var(--mdg-shadow);
    list-style: none !important;
}

.site-navigation .mod-menu li:hover > ul,
.site-navigation .mod-menu li:focus-within > ul,
.site-navigation .mod-menu li.open > ul,
.site-navigation .mod-menu li.active.deeper > ul.mm-show {
    display: flex;
}

.site-navigation .mod-menu li > ul a {
    width: 100%;
}

.menu-toggle {
    display: none;
    align-items: center;
    gap: 0.55rem;
    min-height: 2.75rem;
    padding: 0.55rem 0.8rem;
    color: #fff;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 0.7rem;
    font-weight: 750;
    cursor: pointer;
}

.menu-toggle-bars {
    display: grid;
    gap: 0.22rem;
}

.menu-toggle-bars i {
    display: block;
    width: 1.1rem;
    height: 0.12rem;
    background: currentColor;
    border-radius: 999px;
    transition: transform 160ms ease, opacity 160ms ease;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bars i:nth-child(1) {
    transform: translateY(0.34rem) rotate(45deg);
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bars i:nth-child(2) {
    opacity: 0;
}

.menu-toggle[aria-expanded="true"] .menu-toggle-bars i:nth-child(3) {
    transform: translateY(-0.34rem) rotate(-45deg);
}

.site-hero {
    position: relative;
    overflow: hidden;
    color: #fff;
    background:
        linear-gradient(125deg, rgba(255, 255, 255, 0.04), transparent 55%),
        color-mix(in srgb, var(--mdg-bg) 84%, #3c285d);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-inner {
    position: relative;
    z-index: 2;
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(11rem, 0.36fr);
    align-items: center;
    gap: 3rem;
    min-height: 22rem;
    padding-block: 4.5rem;
}

.hero-copy {
    max-width: 48rem;
}

.eyebrow {
    margin: 0 0 0.75rem;
    color: var(--mdg-play);
    font-size: 0.82rem;
    font-weight: 900;
    letter-spacing: 0.16em;
    text-transform: uppercase;
}

.hero-copy h1 {
    max-width: 15ch;
    margin: 0;
    color: #fff;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2.5rem, 7vw, 5.4rem);
    font-weight: 700;
    letter-spacing: -0.045em;
    line-height: 0.98;
    text-wrap: balance;
}

.hero-copy > p:last-child {
    max-width: 42rem;
    margin: 1.4rem 0 0;
    color: rgba(255, 255, 255, 0.75);
    font-size: clamp(1rem, 2vw, 1.17rem);
    line-height: 1.7;
}

.hero-tokens {
    position: relative;
    min-height: 14rem;
}

.token {
    position: absolute;
    display: grid;
    place-items: center;
    width: 6rem;
    aspect-ratio: 1;
    color: var(--mdg-ink);
    background: var(--mdg-accent);
    border: 0.35rem solid rgba(255, 255, 255, 0.2);
    border-radius: 1.25rem;
    font-family: Georgia, "Times New Roman", serif;
    font-size: 2.1rem;
    font-weight: 900;
    box-shadow: 0.8rem 1.1rem 0 rgba(0, 0, 0, 0.15);
    transform: rotate(9deg);
}

.token-one {
    top: 0;
    right: 1rem;
}

.token-two {
    bottom: 0.3rem;
    left: 0;
    width: 5.2rem;
    color: var(--mdg-bg);
    background: var(--mdg-play);
    transform: rotate(-13deg);
}

.token-three {
    right: 0;
    bottom: -1.1rem;
    width: 4.4rem;
    color: #fff;
    background: var(--mdg-coral);
    transform: rotate(19deg);
}

.hero-orbit {
    position: absolute;
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 50%;
    pointer-events: none;
}

.hero-orbit-one {
    top: -13rem;
    right: -8rem;
    width: 35rem;
    height: 35rem;
}

.hero-orbit-two {
    right: 9rem;
    bottom: -16rem;
    width: 28rem;
    height: 28rem;
}

.breadcrumbs-wrap {
    padding-block: 1rem;
    color: rgba(255, 255, 255, 0.67);
    font-size: 0.92rem;
}

.breadcrumbs-wrap .breadcrumb {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem;
    margin: 0;
    padding: 0;
    list-style: none;
}

.breadcrumbs-wrap a {
    color: #fff;
}

.main-shell {
    padding-block: clamp(1.5rem, 4vw, 3rem) clamp(3rem, 7vw, 6rem);
}

.content-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1.5rem;
    align-items: start;
}

.content-grid-sidebar {
    grid-template-columns: minmax(0, 1fr) minmax(15rem, 20rem);
}

.content-panel,
.sidebar > .moduletable,
.sidebar > .module,
.sidebar > section,
.sidebar > div {
    background: var(--mdg-paper);
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: var(--mdg-radius);
    box-shadow: var(--mdg-shadow);
}

.content-panel {
    min-width: 0;
    padding: clamp(1.15rem, 4vw, 2.5rem);
}

.sidebar {
    display: grid;
    gap: 1rem;
}

.sidebar > .moduletable,
.sidebar > .module,
.sidebar > section,
.sidebar > div {
    overflow: hidden;
    padding: 1.35rem;
}

.sidebar h2,
.sidebar h3 {
    margin-top: 0;
    padding-bottom: 0.65rem;
    border-bottom: 0.2rem solid var(--mdg-accent);
    font-family: Georgia, "Times New Roman", serif;
    line-height: 1.2;
}

.sidebar ul {
    padding-left: 1.2rem;
}

.module-band {
    color: #fff;
    padding-block: 1rem;
}

.module-band-after {
    padding-bottom: 3rem;
}

.content-panel h1,
.content-panel h2,
.content-panel h3,
.content-panel h4 {
    color: var(--mdg-ink);
    font-family: Georgia, "Times New Roman", serif;
    line-height: 1.18;
    text-wrap: balance;
}

.content-panel h1 {
    margin-top: 0;
    font-size: clamp(2rem, 5vw, 3.5rem);
    letter-spacing: -0.035em;
}

.content-panel h2 {
    font-size: clamp(1.5rem, 3vw, 2.15rem);
}

.page-header {
    margin-bottom: 1.5rem;
}

.page-header h1,
.page-header h2 {
    margin-bottom: 0.25rem;
}

.button,
.btn,
button[type="submit"],
input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 2.75rem;
    padding: 0.62rem 1rem;
    color: var(--mdg-ink);
    background: var(--mdg-accent);
    border: 1px solid color-mix(in srgb, var(--mdg-accent) 65%, #000);
    border-radius: 0.7rem;
    font-weight: 850;
    line-height: 1.25;
    text-decoration: none;
    cursor: pointer;
    transition: transform 140ms ease, box-shadow 140ms ease, background 140ms ease;
}

.button:hover,
.btn:hover,
button[type="submit"]:hover,
input[type="submit"]:hover {
    color: var(--mdg-ink);
    background: color-mix(in srgb, var(--mdg-accent) 86%, #fff);
    box-shadow: 0 0.45rem 1rem rgba(29, 25, 48, 0.14);
    transform: translateY(-1px);
}

.btn-secondary,
.button.secondary,
button[type="reset"] {
    color: var(--mdg-ink);
    background: #fff;
    border-color: var(--mdg-line);
}

input[type="text"],
input[type="email"],
input[type="password"],
input[type="search"],
input[type="number"],
input[type="url"],
select,
textarea {
    width: 100%;
    min-height: 2.75rem;
    padding: 0.62rem 0.75rem;
    color: var(--mdg-ink);
    background: #fff;
    border: 1px solid #cfc8bc;
    border-radius: 0.65rem;
}

textarea {
    min-height: 8rem;
    resize: vertical;
}

input:focus,
select:focus,
textarea:focus {
    border-color: #7d65b4;
    box-shadow: 0 0 0 0.2rem rgba(102, 209, 197, 0.26);
    outline: none;
}

label {
    display: inline-block;
    margin-bottom: 0.3rem;
    font-weight: 750;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 0.75rem;
    border-bottom: 1px solid var(--mdg-line);
    text-align: left;
    vertical-align: top;
}

th {
    color: #fff;
    background: var(--mdg-purple);
}

.alert,
.joomla-alert {
    margin-bottom: 1rem;
    padding: 0.85rem 1rem;
    background: #fff;
    border: 1px solid var(--mdg-line);
    border-left: 0.35rem solid var(--mdg-play);
    border-radius: 0.7rem;
}

.alert-danger,
.joomla-alert--danger {
    border-left-color: var(--mdg-coral);
}

.pagination,
.pagination ul {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin: 1.5rem 0 0;
    padding: 0;
    list-style: none;
}

.pagination a,
.pagination span {
    display: grid;
    min-width: 2.45rem;
    min-height: 2.45rem;
    place-items: center;
    padding: 0.35rem 0.65rem;
    background: #fff;
    border: 1px solid var(--mdg-line);
    border-radius: 0.55rem;
    text-decoration: none;
}

.pagination .active span,
.pagination .active a {
    color: var(--mdg-ink);
    background: var(--mdg-accent);
    border-color: var(--mdg-accent);
    font-weight: 850;
}

.site-footer {
    color: rgba(255, 255, 255, 0.72);
    background: color-mix(in srgb, var(--mdg-bg) 82%, #000);
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-inner {
    padding-block: 2.5rem;
}

.footer-modules {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.footer-modules h2,
.footer-modules h3 {
    color: #fff;
}

.footer-modules a {
    color: var(--mdg-play);
}

.footer-signoff {
    margin: 0;
    font-size: 0.9rem;
}

.component-only {
    min-height: 100vh;
    padding: 1.5rem;
    background: #fff;
}

.component-shell {
    width: min(100%, var(--mdg-width));
    margin-inline: auto;
}

.error-page {
    display: grid;
    min-height: 100vh;
    place-items: center;
    padding: 1rem;
}

.error-shell {
    width: min(100%, 40rem);
}

.error-card {
    padding: clamp(1.5rem, 6vw, 4rem);
    text-align: center;
    background: var(--mdg-paper);
    border-radius: 1.5rem;
    box-shadow: var(--mdg-shadow);
}

.error-card h1 {
    margin-top: 0;
    font-family: Georgia, "Times New Roman", serif;
    font-size: clamp(2rem, 6vw, 4rem);
    line-height: 1;
}

.error-code {
    margin: 0;
    color: var(--mdg-coral);
    font-size: 4rem;
    font-weight: 950;
    line-height: 1;
}

@media (max-width: 820px) {
    .header-inner {
        min-height: 4.5rem;
    }

    .js .menu-toggle {
        display: inline-flex;
        margin-left: auto;
    }

    .site-navigation {
        position: fixed;
        z-index: 30;
        top: 4.5rem;
        right: 0;
        bottom: 0;
        left: 0;
        display: block;
        overflow-y: auto;
        padding: 1rem;
        background: color-mix(in srgb, var(--mdg-bg) 97%, transparent);
        backdrop-filter: blur(1rem);
    }

    .js .site-navigation {
        display: none;
    }

    .js .site-navigation.is-open {
        display: block;
    }

    .site-navigation .mod-menu {
        display: flex;
        flex-direction: column;
        align-items: stretch;
        gap: 0.2rem;
        width: 100%;
        margin: 0;
        padding: 0;
        list-style: none !important;
    }

    .site-navigation .mod-menu > li {
        width: 100%;
    }

    .site-navigation .mod-menu a,
    .site-navigation .mod-menu .nav-header,
    .site-navigation .mod-menu .separator {
        width: 100%;
        min-height: 3.1rem;
        padding-inline: 1rem;
    }

    .site-navigation .mod-menu li > ul {
        position: static;
        display: none;
        width: calc(100% - 1rem);
        min-width: 0;
        margin-left: 1rem;
        padding: 0 0 0 0.55rem;
        background: transparent;
        border: 0;
        border-left: 1px solid rgba(255, 255, 255, 0.15);
        border-radius: 0;
        box-shadow: none;
    }

    .site-navigation .mod-menu li:hover > ul,
    .site-navigation .mod-menu li:focus-within > ul,
    .site-navigation .mod-menu li.open > ul,
    .site-navigation .mod-menu li > ul.mm-show {
        display: flex;
    }

    .hero-inner {
        grid-template-columns: 1fr;
        gap: 1.25rem;
        min-height: 0;
        padding-block: 3.25rem;
    }

    .hero-tokens {
        display: none;
    }

    .content-grid-sidebar {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 520px) {
    .header-inner,
    .hero-inner,
    .breadcrumbs-wrap,
    .main-shell,
    .module-band,
    .footer-inner {
        width: min(calc(100% - 1.25rem), var(--mdg-width));
    }

    .brand-copy small {
        display: none;
    }

    .menu-toggle > span:last-child {
        position: absolute;
        width: 1px;
        height: 1px;
        overflow: hidden;
        clip: rect(0 0 0 0);
        clip-path: inset(50%);
        white-space: nowrap;
    }

    .hero-copy h1 {
        font-size: clamp(2.35rem, 14vw, 3.7rem);
    }

    .content-panel {
        border-radius: 0.85rem;
    }

    th,
    td {
        padding: 0.55rem;
    }
}

[dir="rtl"] .site-navigation .mod-menu li > ul {
    right: 0;
    left: auto;
}

[dir="rtl"] .alert,
[dir="rtl"] .joomla-alert {
    border-right: 0.35rem solid var(--mdg-play);
    border-left-width: 1px;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        scroll-behavior: auto !important;
        transition-duration: 0.01ms !important;
    }
}
