
:root {
    --bg: #0b1014; /* deep sea */
    --bg-2: #0c1a22; /* dusk */
    --ink: #e8e6e3; /* parchment text */
    --muted: #b9b7b3;
    --gold: #d6b25e; /* doubloons */
    --blood: #b33a3a;
    --rope: #ab8551;
    --paper: #f6ecd3; /* parchment */
    --paper-ink: #2b2b2b;
    --focus: #4dd1ff;
    --accent: #6ec4a7; /* seafoam */
    --accent-2: #c98a2c; /* rum */
    --max: 1100px;
}

/* Reset-ish */
* {
    box-sizing: border-box
}

html, body {
    height: 100%
}

html {
    scroll-behavior: smooth
}

body {
    margin: 0;
    font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Inter, "Helvetica Neue", Arial, "Apple Color Emoji", "Segoe UI Emoji";
    line-height: 1.65;
    color: var(--ink);
    background: radial-gradient(1200px 700px at 20% 0%, #112633 0%, transparent 60%),
    radial-gradient(1200px 700px at 80% 100%, #0c2431 0%, transparent 60%),
    linear-gradient(180deg, var(--bg) 0%, var(--bg-2) 100%);
    overflow-x: hidden;
}

/* Subtle film grain */
body::before {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: .08;
    mix-blend-mode: soft-light;
    background-image: repeating-radial-gradient(#000 0 1px, transparent 2px 6px);
}

.container {
    max-width: var(--max);
    margin-inline: auto;
    padding: clamp(16px, 2.5vw, 32px)
}

/* Header / Nav */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    background: rgba(10, 16, 20, .85);
    backdrop-filter: blur(6px);
    border-bottom: 1px solid #13222c
}

.nav-wrap {
    display: flex;
    align-items: center;
    gap: 16px
}

.brand {
    display: flex;
    align-items: center;
    gap: 12px;
    font-weight: 800;
    letter-spacing: .5px;
    text-transform: uppercase
}

.brand .logo {
    width: 28px;
    height: 28px;
    display: inline-block
}

.brand .wordmark {
    background: linear-gradient(180deg, #ffd77a, #d6b25e 60%, #a07b2d);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent
}

nav[aria-label="Primary"] {
    margin-left: auto
}

.menu {
    display: flex;
    gap: 18px;
    list-style: none;
    margin: 0;
    padding: 0
}

.menu a {
    display: inline-block;
    padding: 10px 12px;
    border-radius: 10px;
    text-decoration: none;
    color: var(--ink);
    font-weight: 600
}

.menu a:hover, .menu a:focus-visible {
    outline: 2px solid transparent;
    background: rgba(255, 215, 122, .08);
    box-shadow: 0 0 0 2px rgba(214, 178, 94, .25) inset
}

.burger {
    display: none;
    gap: 8px;
    align-items: center;
    margin-left: auto;
    border: 1px solid #22323d;
    border-radius: 12px;
    padding: 10px 12px;
    background: #0f171c;
    color: var(--ink);
    cursor: pointer
}

.burger .lines {
    width: 20px;
    height: 14px;
    position: relative;
    display: inline-block
}

.burger .lines::before, .burger .lines::after, .burger .lines span {
    content: "";
    position: absolute;
    left: 0;
    right: 0;
    height: 2px;
    background: var(--ink);
    border-radius: 2px;
    transition: transform .35s ease, opacity .25s ease
}

.burger .lines::before {
    top: 0
}

.burger .lines span {
    top: 6px
}

.burger .lines::after {
    bottom: 0
}

/* Hero Slider */
.hero {
    position: relative;
    isolation: isolate
}

.slider {
    position: relative;
    border: 1px solid #1a2a33;
    border-radius: 20px;
    overflow: hidden
}

.slides {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: 100%;
    transition: transform .6s cubic-bezier(.2, .7, .2, 1)
}

.slide {
    min-height: 360px;
    display: grid;
    align-content: center;
    justify-items: start;
    padding: clamp(24px, 6vw, 64px);
    position: relative
}

.slide h2 {
    margin: 0 0 6px;
    font-size: clamp(28px, 4vw, 44px);
    line-height: 1.12
}

.slide p {
    max-width: 60ch;
    margin: 0 0 16px;
    color: var(--muted)
}

.slide .cta {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 10px 14px;
    border-radius: 12px;
    border: 1px solid #2a3b46;
    background: #0f181d;
    color: var(--ink);
    text-decoration: none;
    font-weight: 700
}

.slide .cta:hover {
    box-shadow: 0 0 0 2px rgba(214, 178, 94, .3) inset
}

/* Slide backgrounds */
.slide--map {
    background: radial-gradient(800px 400px at 110% 0%, rgba(214, 178, 94, .15), transparent 60%),
    radial-gradient(800px 400px at -10% 100%, rgba(110, 196, 167, .18), transparent 60%),
    conic-gradient(from 200deg at 120% -10%, rgba(255, 215, 122, .16), transparent 40%),
     url("picture/1.jpg") center/cover no-repeat,
    linear-gradient(180deg, #0a151a, #0c1a22 70%);
}

.slide--chest {
    background: radial-gradient(600px 280px at 80% 20%, rgba(179, 58, 58, .18), transparent 70%),
    radial-gradient(600px 280px at 0% 100%, rgba(214, 178, 94, .18), transparent 70%),
     url("picture/2.jpg") center/cover no-repeat,
    linear-gradient(180deg, #0a1419, #0b171f 70%);
}

.slide--compass {
    background: radial-gradient(700px 320px at 0% 0%, rgba(110, 196, 167, .15), transparent 60%),
    radial-gradient(700px 320px at 100% 100%, rgba(255, 215, 122, .15), transparent 60%),
     url("picture/3.jpg") center/cover no-repeat,
    linear-gradient(180deg, #0b161b, #0d1c24 70%);
}
.slide--map h2,
.slide--map p {
    color: #fff;
    text-shadow: 0 2px 6px rgba(0,0,0,0.8);
}

.slide--chest h2,
.slide--chest p {
    color: #fff;
    text-shadow: 0 2px 6px rgba(0,0,0,0.8);
}

.slide--compass h2,
.slide--compass p {
    color: #fff;
    text-shadow: 0 2px 6px rgba(0,0,0,0.8);
}
/* Slider controls */
.controls {
    position: absolute;
    inset: auto 0 12px 0;
    display: flex;
    justify-content: space-between;
    gap: 12px;
    pointer-events: none;
    padding-inline: 12px
}

.control {
    pointer-events: auto;
    border: 1px solid #26414e;
    background: #0f181d;
    color: var(--ink);
    border-radius: 12px;
    padding: 10px 12px;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    cursor: pointer
}

.dots {
    position: absolute;
    left: 50%;
    bottom: 12px;
    transform: translateX(-50%);
    display: flex;
    gap: 10px
}

.dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    border: 1px solid #3a505d;
    background: transparent;
    cursor: pointer
}

.dot[aria-current="true"] {
    background: var(--gold);
    border-color: transparent
}

/* Pirate ornaments */
.orn {
    display: inline-grid;
    grid-auto-flow: column;
    gap: 8px;
    align-items: center
}

.orn svg {
    opacity: .9
}

/* Typography & layout on the provided content */
body > h1,
body > h2,
body > h3,
body > p,
body > ul,
body > table {
    max-width: var(--max);
    margin-inline: auto
}

body > h1 {
    margin-top: 48px
}

body > * {
    padding-inline: clamp(16px, 2.5vw, 32px)
}

h1, h2 {
    font-weight: 900;
    letter-spacing: .2px
}

h1 {
    font-size: clamp(32px, 4.8vw, 54px);
    line-height: 1.08;
    background: linear-gradient(180deg, #ffe39b, #d6b25e 60%, #9e7a2d);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    text-shadow: 0 1px 0 rgba(0, 0, 0, .2)
}

h2 {
    font-size: clamp(24px, 3.4vw, 34px);
    color: #f5d78a
}

h3 {
    font-size: clamp(18px, 2.4vw, 22px);
    color: #e9d7a4
}

p, li {
    color: var(--ink)
}

a {
    color: var(--gold)
}

/* Parchment-style tables */
table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    background: linear-gradient(180deg, #f7efd7, #efe1be);
    color: var(--paper-ink);
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 10px 30px rgba(0, 0, 0, .25)
}

table th, table td {
    border: 0;
    padding: 14px 16px
}

table thead th {
    background: repeating-linear-gradient(45deg, rgba(214, 178, 94, .22) 0 10px, rgba(214, 178, 94, .1) 10px 20px);
    text-align: left;
    color: #3a2a10;
    font-weight: 800
}

table tr:nth-child(odd) td {
    background: rgba(255, 255, 255, .46)
}

table tr + tr td {
    border-top: 1px dashed rgba(92, 62, 28, .35)
}

table {
    border: 10px solid transparent;
    border-image: repeating-linear-gradient(90deg, #a57b3a 0 14px, #c59a58 14px 28px) 30
}

/* Lists with treasure markers */
ul {
    list-style: none;
    padding-left: 0
}

ul li {
    position: relative;
    padding-left: 28px
}

ul li::before {
    content: "";
    position: absolute;
    left: 0;
    top: .7em;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: radial-gradient(circle at 30% 30%, #ffe39b, #d6b25e 60%, #8a6423);
    box-shadow: 0 1px 0 rgba(0, 0, 0, .3)
}

/* Cards (we'll auto-wrap sections) */
body > h2 {
    margin-top: 56px
}

body > h2 + p,
body > h2 + ul,
body > h2 + table {
    background: rgba(255, 255, 255, .03);
    border: 1px solid #182830;
    border-radius: 16px;
    padding: 18px 20px;
    margin-top: 12px;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .18)
}

/* Back-to-top coin */
.to-top {
    position: fixed;
    right: 14px;
    bottom: 14px;
    width: 46px;
    height: 46px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    color: #2e2310;
    background: radial-gradient(circle at 30% 30%, #ffe39b, #d6b25e 60%, #8a6423);
    border: 1px solid #7d5d22;
    box-shadow: 0 6px 18px rgba(0, 0, 0, .4);
    text-decoration: none;
    font-weight: 900
}

.to-top:focus-visible {
    outline: 3px solid var(--focus)
}

/* Footer */
footer {
    margin-top: 60px;
    border-top: 1px solid #16242d;
    background: linear-gradient(180deg, rgba(214, 178, 94, .08), transparent), #0a1419
}

footer .foot {
    display: flex;
    flex-wrap: wrap;
    gap: 14px;
    align-items: center;
    justify-content: space-between
}

footer p {
    margin: 0;
    color: #c9c6c2
}

/* Responsive nav */
@media (max-width: 992px) {
    .menu {
        display: none;
        position: fixed;
        inset: 64px 12px auto 12px;
        background: #0b1419;
        border: 1px solid #23303a;
        border-radius: 18px;
        padding: 14px;
        flex-direction: column;
        z-index: 60
    }

    .menu.open {
        display: flex
    }

    .burger {
        display: inline-flex
    }

    .brand {
        font-size: 14px
    }

    .slide {
        min-height: 420px
    }
}

/* Reduced motion consideration */
@media (prefers-reduced-motion: reduce) {
    .slides {
        transition: none
    }

    .burger .lines::before, .burger .lines span, .burger .lines::after {
        transition: none
    }
}
