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

img {
    max-width: 100%;
}

* {
    min-width: 0;
    scrollbar-width: thin;
    scrollbar-color: #caa45a #10151d;
}

html,
body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;
}

.grid {
    min-width: 0;
}

.panel {
    display: flex;
    position: relative;
    flex-direction: column;
    gap: 12px;
    min-width: 0;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background: linear-gradient(180deg,rgba(255,255,255,.035) , rgba(255,255,255,.015));
    background-color: var(--panel);
    box-shadow: 0 15px 35px rgba(0,0,0,.35), inset 0 1px rgba(255,255,255,.04) ,0 0 25px rgba(92,184,255,.04);
    animation: fadeUp .45s ease;
    isolation: isolate;
    clip-path: polygon(0 14px,14px 0,calc(100% - 14px) 0,100% 14px,100% calc(100% - 14px), calc(100% - 14px) 100%,14px 100%,0 calc(100% - 14px));
}

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

html {
    font-size: 16px;
    scroll-behavior: smooth;
    scroll-padding-top: 90px;
}

body {
    position: relative;
    margin: 0;
    min-height: 100vh;
    font-family: "Inter",sans-serif;
    font-size: 14px;
    color: #EDF2F7;
    background: radial-gradient(circle at top,#1A2434 0%,#111822 35%,#090C12 100%);
}

:root {
    --bg: #070B11;
    --bg2: #0E1520;
    --panel: #141B26;
    --panel2: #1A2330;
    --gold: #C6A96A;
    --gold-light: #E8CC8A;
    --blue: #5CB8FF;
    --cyan: #6FE9FF;
    --text: #EDF2F7;
    --muted: #8C97A6;
    --border: #314254;
    --border-light: #5B7087;
    --radius: 16px;
    --gap: 12px;
    --padding: 14px;
    --header: 72px;
    --footer: 48px;
    --left: 380px;
    --right: 380px;
    --panel-radius: 16px;
    --panel-border: #314254;
    --panel-hover: #C6A96A;
    --transition: .25s;
    --shadow: 0 12px 30px rgba(0,0,0,.35);
}

#background {
position: fixed;
opacity: .25;
background: radial-gradient(circle at center,rgba(111,233,255,.08), transparent 60%);
pointer-events: none;
inset: 0;
}

#overlay {
position: fixed;
opacity: .08;
background-image: linear-gradient(rgba(255,255,255,.08) 1px,transparent 1px), linear-gradient(90deg,rgba(255,255,255,.08) 1px,transparent 1px);
background-size: 40px 40px;
pointer-events: none;
inset: 0;
}

body::after {
    content: "";
    position: fixed;
    background: radial-gradient(circle,transparent 55%,rgba(0,0,0,.45) 100%);
    pointer-events: none;
    inset: 0;
}

#codex {
display: grid;
position: relative;
grid-template-rows: var(--header) minmax(0,1fr) var(--footer);
grid-template-columns: var(--left) minmax(0,1fr) var(--right);
gap: var(--gap);
padding: var(--gap);
}

#topbar {
display: grid;
grid-template-columns: 320px 1fr 260px;
align-items: center;
gap: 20px;
padding: 0 20px;
border: 1px solid var(--border);
border-radius: var(--radius);
background: linear-gradient(180deg,rgba(255,255,255,.03) , rgba(255,255,255,.01));
box-shadow: 0 10px 30px rgba(0,0,0,.35);
grid-column: 1 / 4;
grid-row: 1;
}

#sidebar-left {
grid-column: 1;
grid-row: 2;
}

#content {
display: flex;
position: relative;
flex-direction: column;
gap: var(--gap);
margin-bottom: 25px;
min-height: 0;
grid-column: 2;
grid-row: 2;
}

#sidebar-right {
grid-column: 3;
grid-row: 2;
}

#statusbar {
display: grid;
grid-template-columns: repeat(4,1fr);
gap: 12px;
grid-column: 1 / 4;
grid-row: 3;
}

::-webkit-scrollbar {
    width: 14px;
    height: 14px;
}

::-webkit-scrollbar-track {
    border-left: 1px solid #2b3a4c;
    background: linear-gradient(180deg,#111821,#0c1118);
}

::-webkit-scrollbar-thumb {
    border: none;
    border-radius: 30px;
    background: transparent;
    box-shadow: none;
}

h1,
h2,
h3,
h4 {
    text-transform: uppercase;
    font-family: "Orbitron",sans-serif;
    font-weight: 600;
    letter-spacing: .12em;
    color: var(--gold-light);
}

h1 {
    font-size: 1.8rem;
}

h2 {
    font-size: 1rem;
}

h3 {
    font-size: .9rem;
}

p {
    line-height: 1.6;
    color: var(--text);
}

small {
    font-size: .7rem;
    color: var(--muted);
}

.panel::before {
    content: "";
    position: absolute;
    border: 1px solid rgba(255,255,255,.05);
    border-radius: 10px;
    pointer-events: none;
    inset: 5px;
    clip-path: inherit;
}

.panel-header {
    position: relative;
    padding: 16px 18px;
    border-bottom: 1px solid rgba(255,255,255,.05);
    overflow: hidden;
}

.panel-header::after {
    content: "";
    position: absolute;
    right: 18px;
    bottom: 0;
    left: 18px;
    height: 1px;
    background: linear-gradient(90deg,transparent,var(--gold), transparent);
}

.panel-content {
    position: relative;
    padding: 24px;
}

img {
    display: block;
    width: 100%;
    height: auto;
}

figure {
    margin: 0;
}

#player-info {
display: flex;
align-items: center;
gap: 15px;
}

.avatar {
    flex-shrink: 0;
    width: 62px;
    height: 62px;
    border: 2px solid var(--gold);
    border-radius: 50%;
    overflow: hidden;
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.identity {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.identity small {
    text-transform: uppercase;
    letter-spacing: .2em;
    color: var(--cyan);
}

.identity h1 {
    font-size: 1.3rem;
}

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

#main-navigation {
display: flex;
gap: 8px;
justify-content: center;
}

#main-navigation button {
display: flex;
position: relative;
flex-direction: column;
align-items: center;
gap: 6px;
justify-content: center;
padding: 10px 18px;
min-width: 95px;
border: 1px solid var(--border-light);
border-radius: 10px;
overflow: hidden;
color: var(--text);
background: linear-gradient(#223245,#18222F);
transition: .25s;
cursor: pointer;
}

#main-navigation button span {
font-size: .72rem;
letter-spacing: .08em;
}

#main-navigation button:hover {
border-color: var(--gold);
box-shadow: 0 0 20px rgba(202,169,106,.20);
transform: translateY(-2px);
}

#main-navigation button.active {
border-color: var(--gold);
background: linear-gradient(#3A4F67,#243241);
}

#system-panel {
display: flex;
gap: 15px;
justify-content: flex-end;
}

.system {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
}

.system strong {
    font-size: .9rem;
    color: var(--cyan);
}

div.system:nth-child(2) > strong:nth-child(2) {
    color: #38f638;
}

div.system:nth-child(3) > strong:nth-child(2) {
    color: #f69138;
}

#sidebar-left,
#sidebar-right {
display: flex;
flex-direction: column;
gap: var(--gap);
}

.character-panel {
    text-align: center;
}

.character-panel .subtitle {
    margin-bottom: 15px;
    color: var(--muted);
}

.portrait {
    width: 180px;
    height: 180px;
    margin: auto;
    border: 4px solid var(--gold);
    border-radius: 50%;
    overflow: hidden;
    box-shadow: 0 0 30px rgba(202,169,106,.25);
}

.character-stats {
    display: grid;
    gap: 4px;
    margin-top: 20px;
}

.info {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    padding: 4px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid rgba(255,255,255,.05);
}

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

.value {
    text-align: right;
}

.status {
    display: grid;
    grid-template-columns: 30px 70px 1fr 70px;
    align-items: center;
    gap: 10px;
    margin-bottom: 12px;
}

.bar {
    height: 10px;
    border-radius: 50px;
    overflow: hidden;
    background: #0B1017;
}

.fill {
    display: block;
    position: relative;
    height: 100%;
    border-radius: 50px;
}

.hp {
    width: 100%;
    background: #58d68d;
}

.mana {
    width: 78%;
    background: #4aa8ff;
}

.patience {
    width: 21%;
    background: #f4d03f;
}

.coffee {
    width: 100%;
    background: #b9770e;
}

.language {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255,255,255,.05);
}

.access {
    margin-top: 15px;
    padding: 10px;
    border: 1px solid var(--gold);
    border-radius: 8px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: .12em;
    color: var(--gold);
}

blockquote {
    text-align: center;
    font-style: italic;
    line-height: 1.5;
    color: #d5d7db;
}

.status-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 18px;
    border: 1px solid var(--border);
    border-radius: 10px;
    background: linear-gradient(#18222E,#121A24);
}

.status-item strong {
    color: var(--cyan);
}

.quest-panel {
    min-height: 230px;
}

.quest-content {
    display: grid;
    grid-template-columns: 90px 1fr 90px;
    align-items: center;
    gap: 25px;
}

.quest-emblem,
.quest-seal {
    display: flex;
    align-items: center;
    justify-content: center;
}

.quest-emblem img,
.quest-seal img {
    width: 150px;
}

.quest-description h1 {
    margin-bottom: 15px;
    font-size: 1.55rem;
    color: var(--gold-light);
}

.quest-description p {
    max-width: 700px;
    color: var(--muted);
}

#guilds {
display: flex;
flex: none;
flex-direction: column;
gap: 15px;
animation: fadeUp .45s ease;
}

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

.guild-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 12px;
    justify-content: center;
}

.guild-card {
    display: flex;
    position: relative;
    flex-direction: column;
    width: 100%;
    border: 1px solid var(--border);
    border-radius: 16px;
    overflow: hidden;
    background: linear-gradient(180deg,#202B39,#151C27);
    box-shadow: 0 12px 25px rgba(0,0,0,.35);
    transition: .25s;
}

.guild-card:hover {
    border-color: var(--gold);
    box-shadow: 0 0 25px rgba(202,169,106,.15) ,0 20px 40px rgba(0,0,0,.45);
    transform: translateY(-6px);
}

.guild-card header {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px;
}

.guild-card header img,
.guild-card header svg {
    display: block;
    flex-shrink: 0;
    width: 42px;
    height: 42px;
}

.guild-card header div {
    display: flex;
    flex-direction: column;
}

.guild-card header small {
    text-transform: uppercase;
    letter-spacing: .15em;
    color: var(--cyan);
}

.guild-card header h3 {
    margin: 3px 0;
    font-size: 14px;
    color: var(--gold-light);
}

.guild-card header span {
    font-size: .8rem;
    color: var(--muted);
}

.guild-card figure {
    height: 180px;
    border-top: 1px solid rgba(255,255,255,.05);
    border-bottom: 1px solid rgba(255,255,255,.05);
    overflow: hidden;
    background: #283241;
    aspect-ratio: 16/8;
}

.guild-card figure img {
    width: 100%;
    height: 100%;
    transition: .4s;
    object-fit: cover;
}

.guild-card:hover figure img {
    transform: scale(1.05);
}

.guild-card section {
    flex: 1;
    padding: 12px;
}

.guild-card ul {
    list-style: none;
}

.guild-card li {
    padding: 6px 0;
    border-bottom: 1px solid rgba(255,255,255,.04);
    font-size: .88rem;
    color: var(--text);
}

.guild-card li:last-child {
    border: none;
}

.guild-card li::before {
    content: "◆ ";
    color: var(--gold);
}

.guild-card footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 10px;
    border-top: 1px solid rgba(255,255,255,.05);
    background: rgba(255,255,255,.02);
}

.guild-card footer span {
    font-size: .8rem;
    color: var(--cyan);
}

.guild-card::before {
    content: "";
    z-index: 0;
    position: absolute;
    border-radius: 16px;
    background: radial-gradient(circle at 5% 5%,rgba(79,150,96,.28), rgba(79,150,96,.08) 50%,transparent 65%);
    pointer-events: none;
    inset: 0;
}

.guild-card.healer::before {
    content: "";
    position: absolute;
    border-radius: 16px;
    background: radial-gradient(circle at 5% 5%,rgba(79,150,96,.28), rgba(79,150,96,.08) 50%,transparent 65%);
    inset: 0;
}

.guild-card.guardian::before {
    content: "";
    position: absolute;
    border-radius: 16px;
    background: radial-gradient(circle at 5% 5%,rgba(70,125,190,.28), rgba(70,125,190,.08) 50%,transparent 65%);
    inset: 0;
}

.guild-card.archivist::before {
    content: "";
    position: absolute;
    border-radius: 16px;
    background: radial-gradient(circle at 5% 5%,rgba(170,122,58,.30), rgba(170,122,58,.09) 50%,transparent 65%);
    inset: 0;
}

.guild-card.developer::before {
    content: "";
    position: absolute;
    border-radius: 16px;
    background: radial-gradient(circle at 5% 5%,rgba(126,92,186,.28), rgba(126,92,186,.08) 50%,transparent 65%);
    inset: 0;
}

.guild-card.explorer::before {
    content: "";
    position: absolute;
    border-radius: 16px;
    background: radial-gradient(circle at 5% 5%,rgba(150,140,68,.28), rgba(150,140,68,.08) 50%,transparent 65%);
    inset: 0;
}

.guild-card.strategist::before {
    content: "";
    position: absolute;
    border-radius: 16px;
    background: radial-gradient(circle at 5% 5%,rgba(150,65,65,.28), rgba(150,65,65,.08) 50%,transparent 65%);
    inset: 0;
}

.guild-card > * {
    z-index: 1;
    position: relative;
}

#bottom-panels {
display: grid;
grid-template-columns: repeat(3,1fr);
flex: none;
gap: 18px;
}

.achievement {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255,255,255,.05);
}

.achievement:last-child {
    border: none;
}

.achievement-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    font-size: 1.2rem;
    background: rgba(202,169,106,.12);
}

.boss {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 18px;
}

.boss header {
    display: flex;
    justify-content: space-between;
}

.boss-life {
    height: 10px;
    border-radius: 30px;
    overflow: hidden;
    background: #0D1218;
}

.life {
    height: 100%;
    border-radius: 30px;
    background: linear-gradient(90deg,#E45D5D,#F8A55A);
}

.hp100 {
    width: 100%;
}

.hp21 {
    width: 21%;
}

.hp42 {
    width: 42%;
}

.hp1 {
    width: 4px;
}

.hp0 {
    width: 0;
}

.quest {
    padding: 12px 0;
    border-bottom: 1px solid rgba(255,255,255,.05);
}

.quest:last-child {
    border: none;
}

.difficulty {
    display: inline-block;
    margin-bottom: 8px;
    padding: 4px 10px;
    border-radius: 30px;
    font-size: .7rem;
}

.inventory-grid {
    display: grid;
    grid-template-columns: repeat(4,1fr);
    gap: 10px;
}

.item {
    display: flex;
    position: relative;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    border-radius: 12px;
    font-size: 2rem;
    background: linear-gradient(180deg,#233041,#16202B);
    transition: .25s;
    cursor: pointer;
    aspect-ratio: 1;
}

.item:hover {
    border-color: var(--gold);
    box-shadow: 0 0 18px rgba(202,169,106,.20);
    transform: translateY(-3px) scale(1.05);
}

.item.empty {
    opacity: .15;
}

.skill-tree {
    display: grid;
    grid-template-columns: repeat(2,1fr);
    gap: 14px;
}

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

.skill-node .icon {
    margin-bottom: 10px;
    font-size: 2rem;
}

.skill-node h4 {
    margin-bottom: 4px;
    font-size: 14px;
}

.skill-node small {
    color: var(--muted);
}

.companion {
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 12px 0;
    border-bottom: 1px solid rgba(255,255,255,.05);
    transition: .25s;
}

.companion:last-child {
    border: none;
}

.companion figure {
    flex-shrink: 0;
    width: 56px;
    height: 56px;
    border: 2px solid var(--gold);
    border-radius: 50%;
    overflow: hidden;
}

.companion img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.companion h4 {
    margin-bottom: 4px;
    color: var(--gold-light);
}

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

button,
.panel,
.guild-card,
.skill-node,
.item,
.companion {
    transition: .25s ease;
}

.panel:hover {
    border-color: var(--gold);
    box-shadow: 0 18px 40px rgba(0,0,0,.45) ,0 0 25px rgba(202,169,106,.08);
}

@keyframes glow {
    0% {
        box-shadow: 0 0 0 rgba(111,233,255,0);
    }

    50% {
        box-shadow: 0 0 18px rgba(111,233,255,.20);
    }

    100% {
        box-shadow: 0 0 0 rgba(111,233,255,0);
    }
}

@keyframes floating {
    0% {
        transform: translateY(0px);
    }

    50% {
        transform: translateY(-4px);
    }

    100% {
        transform: translateY(0px);
    }
}

@keyframes fadeUp {
    from {
        opacity: 0;
        transform: translateY(15px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.panel::after {
    content: "";
    position: absolute;
    top: 18px;
    right: 18px;
    width: 18px;
    height: 18px;
    border-top: 2px solid var(--gold);
    border-right: 2px solid var(--gold);
    background: linear-gradient(135deg,rgba(255,255,255,.03) , transparent 20%);
    pointer-events: none;
    inset: 0;
}

.panel-header::before {
    content: "";
    position: absolute;
    top: 0;
    left: 0;
    width: 80px;
    height: 3px;
    background: var(--gold);
}

.panel .corner {
    position: absolute;
    width: 14px;
    height: 14px;
    border-color: var(--gold);
}

.corner.tl {
    top: 8px;
    left: 8px;
    border-top: 2px solid;
    border-left: 2px solid;
}

.corner.tr {
    top: 8px;
    right: 8px;
    border-top: 2px solid;
    border-right: 2px solid;
}

.corner.bl {
    bottom: 8px;
    left: 8px;
    border-bottom: 2px solid;
    border-left: 2px solid;
}

.corner.br {
    right: 8px;
    bottom: 8px;
    border-right: 2px solid;
    border-bottom: 2px solid;
}

body::before {
    content: "";
    position: fixed;
    opacity: .05;
    background: radial-gradient(circle at 18% 22%,rgba(0,170,255,.05), transparent 40%), radial-gradient(circle at 82% 78%,rgba(255,185,70,.05), transparent 45%);
    pointer-events: none;
    inset: 0;
}

#background::after {
content: "";
position: absolute;
opacity: .04;
background-image: url("../img/noise.png");
inset: 0;
mix-blend-mode: overlay;
}

.panel-header h2 {
    display: flex;
    align-items: center;
    gap: 12px;
    letter-spacing: .15em;
}

button {
    position: relative;
    overflow: hidden;
}

button::before {
    content: "";
    position: absolute;
    top: 0;
    left: -120%;
    width: 80%;
    height: 100%;
    background: linear-gradient(90deg,transparent,rgba(255,255,255,.15) , transparent);
    transition: .5s;
}

button:hover::before {
    left: 120%;
}

.guild-card::after {
    content: "";
    position: absolute;
    top: 0;
    right: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg,transparent,var(--gold), transparent);
}

.item::after {
    content: "";
    position: absolute;
    border: 1px solid rgba(255,255,255,.04);
    inset: 4px;
}

.skill-node::after {
    content: "";
    position: absolute;
    border: 1px solid rgba(255,255,255,.04);
    border-radius: 10px;
    inset: 5px;
}

.companion:hover {
    border-radius: 10px;
    background: rgba(255,255,255,.03);
}

.fill::after {
    content: "";
    position: absolute;
    background: linear-gradient(rgba(255,255,255,.18) , transparent);
    inset: 0;
}

.guild-card:hover,
.skill-node:hover,
.item:hover {
    z-index: 5;
}

button,
.guild-card,
.item,
.skill-node {
    cursor: pointer;
}

.panel-header h2::before {
    content: "";
    width: 22px;
    height: 2px;
    background: var(--gold);
}

.panel-header small {
    position: absolute;
    top: 16px;
    right: 18px;
    font-size: .65rem;
    letter-spacing: .25em;
    opacity: .4;
}

.panel-content::before {
    content: "";
    position: absolute;
    top: 20px;
    left: 0;
    width: 4px;
    height: 40px;
    background: var(--gold);
}

#sidebar-left,
#content,
#sidebar-right {
align-self: stretch;
min-height: 0;
}

.guild-card header img {
    width: 42px;
    height: 42px;
    object-fit: contain;
}

.skill-node {
    display: flex;
    position: relative;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 160px;
    padding: 10px;
    border: 1px solid var(--border);
    border-radius: 14px;
    text-align: center;
    background: linear-gradient(180deg,#202C3A,#16202B);
    transition: .25s;
}

.legendary {
    border-color: #d97706;
    color: #F6C65B;
}

.epic {
    border-color: #7c3aed;
    color: #A35DFF;
}

.master {
    border-color: #d8b764;
}

.rare {
    border-color: #2563eb;
    color: #4DA3FF;
}

.uncommon {
    border-color: #16a34a;
    color: #53D769;
}

.common {
    border-color: #5b7087;
    color: #CFCFCF;
}

.guild-card h3 {
    font-size: .9rem;
}

::-webkit-scrollbar-thumb:hover {
    background: linear-gradient(180deg,#edd28d,#c39c51);
}

::-webkit-scrollbar-corner {
    background: #111821;
}

#codex-scroll-indicator {
position: absolute;
right: 18px;
}

#content::before {
display: block;
position: sticky;
right: 8px;
bottom: 0;
left: 0;
opacity: 1;
background: linear-gradient(to bottom,rgba(20,27,38,0) , rgba(20,27,38,.65) 70%,rgba(20,27,38,1) 100%);
transition: opacity .25s;
pointer-events: none;
}

#content.at-bottom::before {
opacity: 0;
}

#scroll-hint {
display: flex;
position: sticky;
bottom: 0;
align-items: center;
justify-content: center;
height: 70px;
margin-top: -70px;
font-size: 2rem;
color: var(--gold);
background: linear-gradient(to bottom, rgba(20,27,38,0) , rgba(203, 203, 179, 0.21));
pointer-events: none;
}

.campaign-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit,minmax(300px,1fr));
    gap: 12px;
    margin-top: 18px;
    margin-bottom: 18px;
}

.campaign-card {
    display: flex;
    position: relative;
    flex-direction: column;
    border: 1px solid rgba(196,166,96,.25);
    border-radius: 14px;
    overflow: hidden;
    background: linear-gradient(180deg,#222b38,#1b2330);
    box-shadow: inset 0 1px rgba(255,255,255,.05) ,0 0 18px rgba(0,0,0,.35);
    transition: .25s;
}

.campaign-card:hover {
    border-color: #cfa95b;
    box-shadow: 0 0 20px rgba(207,169,91,.18);
    transform: translateY(-3px);
}

.tooltip {
    visibility: hidden;
    position: absolute;
    top: 85px;
    left: 50%;
    width: 260px;
    padding: 16px;
    border: 1px solid #C8A45C;
    border-radius: 10px;
    font-size: 12px;
    opacity: 0;
    background: #121924;
    box-shadow: 0 20px 45px rgba(0,0,0,.45);
    transition: .18s;
    transform: translateX(-50%) translateY(8px);
}

.item:hover .tooltip {
    visibility: visible;
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

.tooltip h3 {
    margin: 0;
    color: #E6C678;
}

.tooltip .type {
    margin-top: 4px;
    font-size: .9rem;
    color: #6DD6FF;
}

.tooltip ul {
    margin: 10px 0;
    padding-left: 18px;
}

.tooltip li {
    margin-bottom: 4px;
}

.tooltip .flavor {
    margin-top: 8px;
    font-style: italic;
    color: #999;
}

.artifact {
    color: #FF6B3D;
}

.inventory-panel {
    z-index: 50;
    position: relative;
    overflow: visible;
    clip-path: none;
}

.svg-email-protection {
    width: 180px;
    margin-top: 5px;
}

.campaign-card::before,
.campaign-card::after {
    content: "";
    position: absolute;
    width: 18px;
    height: 18px;
    border-color: #cfa95b;
}

.campaign-card::before {
    top: 12px;
    left: 12px;
    border-top: 2px solid;
    border-left: 2px solid;
}

.campaign-card::after {
    right: 12px;
    bottom: 12px;
    border-right: 2px solid;
    border-bottom: 2px solid;
}

.campaign-card header {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 22px;
    border-bottom: 1px solid rgba(255,255,255,.06);
}

.campaign-card .icon {
    display: flex;
    flex-shrink: 0;
    align-items: center;
    justify-content: center;
    width: 56px;
    height: 56px;
    border: 1px solid #cfa95b;
    border-radius: 50%;
    font-size: 28px;
    background: radial-gradient(circle,#364252,#212935);
}

.campaign-card small {
    display: block;
    text-transform: uppercase;
    font-size: .72rem;
    letter-spacing: .18em;
    color: #7f8b9b;
}

.campaign-card h3 {
    margin: 4px 0;
    font-size: 1.45rem;
    letter-spacing: .04em;
    color: #d8bb73;
}

.campaign-card header span:last-child {
    font-size: .95rem;
    color: #9fa9b6;
}

.campaign-card section {
    flex: 1;
    padding: 20px 24px;
}

.campaign-card ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.campaign-card li {
    position: relative;
    padding: 8px 0 8px 22px;
    border-bottom: 1px solid rgba(255,255,255,.05);
    color: #d7dce3;
}

.campaign-card li:last-child {
    border-bottom: none;
}

.campaign-card li::before {
    content: "◆";
    position: absolute;
    left: 0;
    font-size: .75rem;
    color: #cfa95b;
}

.campaign-card footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 24px;
    border-top: 1px solid rgba(255,255,255,.06);
}

.campaign-card footer span {
    font-size: .95rem;
    font-weight: 600;
    color: #6fe3ff;
}

.campaign-card footer::after {
    content: "MISSION TERMINÉE";
    font-size: .72rem;
    letter-spacing: .18em;
    color: #57d96b;
}

.campaign-level {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    width: 72px;
    margin-right: 18px;
    min-width: 72px;
}

.campaign-level .lvl {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 54px;
    height: 54px;
    border: 2px solid #cfa95b;
    border-radius: 50%;
    font-size: 1.55rem;
    font-weight: 700;
    line-height: 1;
    color: #f6e3a2;
    background: radial-gradient(circle at 30% 30%,#364252 0%,#28313d 70%,#1b2330 100%);
    box-shadow: inset 0 0 8px rgba(255,255,255,.08) ,0 0 12px rgba(207,169,91,.15);
}

.campaign-level small {
    margin-top: 8px;
    text-transform: uppercase;
    font-size: .65rem;
    letter-spacing: .25em;
    color: #7d8796;
}

#campaigns {
margin-top: 18px;
}

.bottom-header h2 {
    margin-bottom: 18px;
}

.testimonials {
    position: relative;
}

.testimonials input {
    display: none;
}

.cards {
    position: relative;
    min-height: 170px;
}

.card {
    display: flex;
    position: absolute;
    flex-direction: column;
    gap: 12px;
    justify-content: center;
    opacity: 0;
    transition: .35s;
    transform: translateX(15px);
    inset: 0;
}

#r1:checked ~ .cards .c1,
#r2:checked ~ .cards .c2,
#r3:checked ~ .cards .c3 {
opacity: 1;
transform: none;
}

.stars {
    font-size: 18px;
    letter-spacing: 2px;
    color: #d4af37;
}

.card footer {
    font-size: .85rem;
    color: #8aa0b9;
}

.controls {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-top: 18px;
}

.controls label {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #38404d;
    transition: .25s;
    cursor: pointer;
}

#r1:checked ~ .controls label:nth-child(1) ,
#r2:checked ~ .controls label:nth-child(2) ,
#r3:checked ~ .controls label:nth-child(3) {
background: #d4af37;
transform: scale(1.2);
}

@keyframes flash {
    from {
        box-shadow: 0 0 0 rgba(212,175,55,0);
    }

    50% {
        box-shadow: 0 0 35px rgba(212,175,55,.35);
    }

    to {
        box-shadow: 0 0 0 rgba(212,175,55,0);
    }
}

#backToTop {
display: flex;
z-index: 999;
position: fixed;
right: 24px;
bottom: 24px;
align-items: center;
justify-content: center;
width: 64px;
height: 64px;
border: 1px solid rgba(212,175,55,.45);
border-radius: 50%;
overflow: hidden;
text-decoration: none;
font-size: 26px;
color: #d4af37;
background: radial-gradient(circle,#2d3745,#1d2531);
box-shadow: 0 8px 20px rgba(0,0,0,.35);
transition: .25s;
}

#backToTop:hover {
border-color: #f0d27c;
box-shadow: 0 0 18px rgba(212,175,55,.35);
transform: translateY(-4px);
}

.item.common {
    border-color: #5b7087;
}

.item.uncommon {
    border-color: #2ea043;
    box-shadow: 0 0 12px rgba(46,160,67,.18);
}

.item.rare {
    border-color: #2f81f7;
    box-shadow: 0 0 15px rgba(47,129,247,.20);
}

.item.epic {
    border-color: #8957e5;
    box-shadow: 0 0 18px rgba(137,87,229,.25);
}

.item.legendary {
    border-color: #d4af37;
    box-shadow: 0 0 10px rgba(212,175,55,.20) ,0 0 22px rgba(212,175,55,.28);
}

.item.artifact {
    border-color: #ff6b35;
    box-shadow: 0 0 15px rgba(255,107,53,.35), inset 0 0 15px rgba(255,107,53,.10);
}

.campaign-card.guardian {
    background: radial-gradient(circle at 15% 15%,rgba(68,110,180,.30), transparent 60%);
}

.campaign-card.developer {
    background: radial-gradient(circle at 15% 15%,rgba(135,92,200,.30), transparent 60%);
}

.campaign-card.engineer {
    background: radial-gradient(circle at 15% 15%,rgba(218,145,62,.28), transparent 60%);
}

.campaign-card.healer {
    background: radial-gradient(circle at 15% 15%,rgba(83,180,170,.24), transparent 60%);
}

.campaign-card.sentinel {
    background: radial-gradient(circle at 15% 15%,rgba(80,110,175,.20), transparent 60%);
}

.skill-title {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.skill-rank {
    margin: 0 auto 0;
    text-transform: uppercase;
    font-size: .72rem;
    letter-spacing: .18em;
    opacity: .75;
}

.skill-rank.apprentice {
    color: #77c36b;
}

.skill-rank.companion {
    color: #58b6ff;
}

.skill-rank.expert {
    color: #ad82ff;
}

.skill-rank.master {
    color: #d8b764;
}

.skill-rank.grandmaster {
    color: #ffb347;
}

.skill-rank.legend {
    color: #ff7452;
}

#main-navigation a {
text-decoration: none;
}

#main-navigation button::after {
content: "";
position: absolute;
background: linear-gradient(120deg,transparent 35%,rgba(255,255,255,.18) 50%,transparent 65%);
transition: transform .6s;
transform: translateX(-180%);
inset: 0;
}

#main-navigation button:hover::after {
transform: translateX(180%);
}

#backToTop::after {
content: "";
position: absolute;
border-radius: 50%;
background: linear-gradient(120deg,transparent 35%,rgba(255,255,255,.22) 50%,transparent 65%);
transition: transform .6s ease;
transform: translateX(-180%);
inset: 0;
}

#backToTop:hover::after {
transform: translateX(180%);
}

#boot-screen {
display: flex;
z-index: 999999;
position: fixed;
align-items: center;
justify-content: center;
background: #090d14;
animation: bootDisappear .8s ease forwards;
animation-delay: 0.01s;
inset: 0;
}

.boot-container {
    width: min(760px,90vw);
}

.boot-container h1 {
    margin-bottom: 40px;
    text-align: center;
    font-size: 42px;
    font-weight: 400;
    letter-spacing: 10px;
    color: #d4b46b;
}

.terminal {
    padding: 25px;
    border: 1px solid #2b3444;
    border-radius: 8px;
    overflow: hidden;
    font-family: monospace;
    line-height: 1.7;
    color: #8fdcff;
    background: #0f1521;
}

.terminal p {
    opacity: 0;
    animation: showLine .01s forwards;
    transform: translateY(8px);
}

.terminal p:nth-child(1) {
    animation-delay: .15s;
}

.terminal p:nth-child(2) {
    animation-delay: .45s;
}

.terminal p:nth-child(3) {
    animation-delay: .75s;
}

.terminal p:nth-child(4) {
    animation-delay: 1.05s;
}

.terminal p:nth-child(5) {
    animation-delay: 1.35s;
}

.terminal p:nth-child(6) {
    animation-delay: 1.65s;
}

.terminal p:nth-child(7) {
    animation-delay: 1.95s;
}

.terminal p:nth-child(8) {
    animation-delay: 2.45s;
}

.success {
    color: #71ff9a;
}

.boot-progress {
    height: 4px;
    margin-top: 30px;
    border-radius: 30px;
    overflow: hidden;
    background: #131b28;
}

.boot-progress span {
    display: block;
    width: 0;
    height: 100%;
    background: linear-gradient(90deg,#55bfff,#7fffd4);
    animation: bootLoading 2.5s linear forwards;
}

.success::after {
    content: "_";
    animation: cursor .8s infinite;
}

@keyframes cursor {
    50% {
        opacity: 0;
    }
}

@keyframes showLine {
    to {
        opacity: 1;
        transform: none;
    }
}

@keyframes bootLoading {
    to {
        width: 100%;
    }
}

@keyframes bootDisappear {
    70% {
        opacity: 1;
    }

    100% {
        visibility: hidden;
        opacity: 0;
    }
}

.boot-container h1::after {
    content: "";
    display: block;
    width: 180px;
    height: 1px;
    margin: 18px auto 0;
    background: linear-gradient(to right,transparent,rgba(201,170,90,.5), transparent);
}

@media (max-width:1600px) {
    :root {
        --left: 300px;
        --right: 300px;
    }
}

@media (max-width:1300px) {
    #codex {
    grid-template-columns: 280px 1fr;
    }

    #sidebar-right {
    display: none;
    }
}

@media (max-width:900px) {
    body {
        overflow: auto;
    }

    :root {
        --gap: 16px;
    }

    #codex {
    display: flex;
    flex-direction: column;
    gap: 16px;
    width: 100%;
    padding: 12px;
    max-width: 100%;
    min-width: 0;
    overflow-x: hidden;
    }

    #topbar {
    display: flex;
    grid-template-columns: 1fr;
    flex-direction: column;
    align-items: center;
    gap: 18px;
    padding: 16px;
    }

    #main-navigation {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    padding-bottom: 6px;
    overflow-x: auto;
    }

    .guild-grid {
        grid-template-columns: 1fr;
    }

    #bottom-panels {
    grid-template-columns: 1fr;
    }

    #sidebar-left {
    order: 1;
    }

    #sidebar-right {
    order: 2;
    }

    #content {
    order: 3;
    }

    #main-navigation button span {
    display: none;
    }

    #main-navigation button {
    padding: 12px;
    min-width: 58px;
    }

    .skill-tree {
        grid-template-columns: 1fr;
        gap: 10px;
    }

    .skill-node {
        width: 100%;
    }

    .status {
        grid-template-columns: 25px 55px 1fr 55px;
    }

    #backToTop {
    right: 16px;
    bottom: 70px;
    width: 52px;
    height: 52px;
    font-size: 22px;
    }

    .campaign-grid {
        display: grid;
        grid-template-columns: 1fr;
    }

    .quest-content {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .quest-emblem,
    .quest-seal {
        justify-content: center;
    }

    .guild-card {
        max-width: none;
    }

    #player-info {
    flex-direction: column;
    text-align: center;
    }

    #system-panel {
    flex-wrap: wrap;
    justify-content: center;
    }

    .cards {
        min-height: 140px;
    }

    .portrait {
        width: 140px;
        height: 140px;
    }

    .guild-card header img,
    .guild-card header svg {
        width: 34px;
        height: 34px;
    }

    .inventory-grid {
        grid-template-columns: repeat(3,1fr);
    }

    #bottom-bar {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding: 12px;
    }

    #bottom-bar > * {
    width: 100%;
    }

    .campaign-card {
        box-sizing: border-box;
        width: 100%;
        max-width: 100%;
        min-width: 0;
    }

    .campaign-title h3 {
        font-size: 1.45rem;
        line-height: 1.05;
    }

    #topbar,
    #sidebar-left,
    #sidebar-right,
    #content,
    #statusbar {
    width: 100%;
    max-width: 100%;
    min-width: 0;
    }

    .panel,
    .guild-card,
    .campaign-card {
        width: 100%;
        max-width: 100%;
    }

    #statusbar {
    grid-template-columns: repeat(2,1fr);
    }

    #statusbar section:nth-child(2) object {
    margin-left: -25px;
    }

    #statusbar section:nth-child(3) {
    display: none;
    }

    #statusbar section:nth-child(4) {
    display: none;
    }

    #statusbar .status-item {
    display: grid;
    }
}

@media (max-width:480px) {
    :root {
        --padding: 10px;
        --gap: 10px;
    }

    .avatar {
        width: 52px;
        height: 52px;
    }

    .portrait {
        width: 120px;
        height: 120px;
    }

    h1 {
        font-size: 1.4rem;
    }

    .guild-card h3 {
        font-size: .8rem;
    }
}
