/*
Theme Name: Chang 123 — Reel Guides
Description: A cool-toned, sidebar-led WordPress theme for casino game and slot guides.
Version: 1.0.0
Requires at least: 6.2
Requires PHP: 8.0
Text Domain: arcade-reels
*/

:root {
    --base: #11132b;
    --aside: #191d3b;
    --card: #20264b;
    --line: #374069;
    --text: #f4f4ff;
    --soft: #bac5e3;
    --cyan: #9beaff;
    --violet: #d1c1ff;
    --sans: system-ui,sans-serif;
    --rail: 208px;
}

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

body {
    margin: 0;
    background: var(--base);
    color: var(--text);
    font: 16px/1.62 var(--sans);
    padding-inline-start: var(--rail);
}

:lang(my) {
    --sans: "Noto Sans Myanmar","Myanmar Sangam MN","Myanmar Text",sans-serif;
}

:lang(km) {
    --sans: "Noto Sans Khmer","Khmer Sangam MN","Khmer UI",sans-serif;
}

:lang(th) {
    --sans: "Noto Sans Thai",Thonburi,"Leelawadee UI",sans-serif;
}

a {
    color: inherit;
}

a:focus-visible {
    outline: 2px solid var(--cyan);
    outline-offset: 3px;
}

img {
    max-width: 100%;
    height: auto;
}

h1,h2,h3 {
    line-height: 1.2;
    overflow-wrap: anywhere;
}

.shell {
    width: min(1190px,calc(100% - 56px));
    margin-inline: auto;
}

.reading-width {
    width: min(820px,calc(100% - 56px));
    margin-inline: auto;
}

.skip-link {
    position: fixed;
    top: .5rem;
    left: .5rem;
    transform: translateY(-150%);
    background: var(--text);
    color: var(--base);
    padding: .45rem;
    z-index: 40;
}

.skip-link:focus {
    transform: translateY(0);
}

.site-header {
    position: fixed;
    inset: 0 auto 0 0;
    width: var(--rail);
    background: var(--aside);
    border-right: 1px solid var(--line);
    overflow-y: auto;
}

.site-header-inner {
    width: auto;
    padding: 2rem 1rem;
    margin: 0;
    display: grid;
    gap: 1.15rem;
}

.brand {
    display: flex;
    align-items: center;
    gap: .55rem;
    min-width: 0;
    color: var(--cyan);
    font-size: 1.17rem;
    font-weight: 800;
    text-decoration: none;
    overflow-wrap: anywhere;
}

.brand-mark {
    width: .75rem;
    height: .75rem;
    background: var(--cyan);
    transform: rotate(45deg);
    flex: 0 0 auto;
}

.header-guides {
    display: block;
    padding: .5rem .65rem;
    border-left: 3px solid var(--cyan);
    background: var(--card);
    text-decoration: none;
    font-weight: 650;
    font-size: .86rem;
}

.languages {
    display: grid;
    gap: .22rem;
}

.languages a {
    padding: .37rem .55rem;
    color: var(--soft);
    font-size: .89rem;
    text-decoration: none;
}

.languages a[aria-current="true"],.languages a:hover {
    background: #303962;
    color: var(--cyan);
}

.reel-hero {
    position: relative;
    isolation: isolate;
    overflow: hidden;
    display: grid;
    align-items: center;
    min-height: 410px;
    margin-top: 1.65rem;
    border-radius: 20px;
    border: 1px solid #545ca4;
    background: #20294c;
}

.reel-hero img {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: 65% 60%;
    z-index: -2;
}

.reel-hero::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    background: linear-gradient(90deg,#171a38 5%,#171a38ed 32%,#171a3838 70%,#171a3817 100%);
}

.reel-copy {
    width: min(100%,540px);
    padding: clamp(1.6rem,5vw,4rem);
}

.reel-copy h1 {
    margin: 0;
    font-size: clamp(2.8rem,6vw,4.9rem);
    font-weight: 800;
    letter-spacing: -.045em;
    text-wrap: balance;
}

.reel-copy p {
    max-width: 24rem;
    color: var(--soft);
    margin: .9rem 0 1.4rem;
}

.reel-copy a {
    display: inline-block;
    background: var(--cyan);
    color: #0d1933;
    border-radius: 6px;
    padding: .53rem .78rem;
    font-weight: 780;
    text-decoration: none;
}

.guide-list {
    padding-block: 2rem 3.5rem;
}

.guide-list>h1,.guide-list>h2 {
    margin: 0 0 1rem;
    font-size: clamp(1.6rem,3vw,2.2rem);
    font-weight: 780;
}

.guide-grid {
    display: grid;
    grid-template-columns: repeat(3,minmax(0,1fr));
    gap: 1rem;
}

.guide-card {
    background: var(--card);
    border: 1px solid var(--line);
    border-radius: 11px;
    overflow: hidden;
}

.guide-card>a {
    display: block;
    height: 100%;
    text-decoration: none;
}

.guide-card>a:hover,.guide-card>a:focus-visible {
    background: #292f5a;
}

.guide-card img {
    display: block;
    aspect-ratio: 16/10;
    object-fit: cover;
    width: 100%;
}

.card-copy {
    padding: .85rem .95rem 1rem;
}

.card-copy time,.article-mast time {
    font-size: .79rem;
    color: var(--violet);
}

.card-copy h2,.card-copy h3 {
    font-size: clamp(1rem,2.1vw,1.25rem);
    margin: .4rem 0 0;
}

.article-mast {
    border-bottom: 1px solid var(--line);
    background: linear-gradient(132deg,#222653,#1c244e 70%,#30316c);
    padding-block: 2.8rem;
}

.entry-title {
    font-size: clamp(2rem,4.7vw,3.8rem);
    margin: .7rem 0;
    letter-spacing: -.025em;
}

.back-guides {
    color: var(--cyan);
    text-underline-offset: .24em;
}

.entry-content {
    padding-block: 2.35rem 3.7rem;
    color: #e8edfb;
    font-size: clamp(1rem,1.9vw,1.14rem);
    overflow-wrap: anywhere;
}

.entry-content img {
    display: block;
    width: 100%;
    border-radius: 10px;
}

.entry-content figure {
    margin: 1rem 0;
}

.entry-content a {
    color: var(--cyan);
    text-underline-offset: .2em;
}

.entry-content h2,.entry-content h3 {
    color: var(--violet);
    margin-top: 1.7em;
}

.entry-content table {
    width: 100%;
    border-collapse: collapse;
    margin-block: 1.2rem;
}

.entry-content th,.entry-content td {
    border: 1px solid var(--line);
    padding: .6rem;
    text-align: start;
}

.entry-content th {
    background: var(--card);
}

.site-footer {
    border-top: 1px solid var(--line);
}

.site-footer-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    min-height: 68px;
}

.site-footer a {
    color: var(--soft);
    text-decoration: none;
}

.site-footer .footer-brand {
    color: var(--cyan);
    font-weight: 750;
}

.screen-reader-text {
    position: absolute;
    clip-path: inset(50%);
    width: 1px;
    height: 1px;
    overflow: hidden;
}

.pagination {
    margin-top: 1rem;
}

:where(html[lang^="th"],html[lang^="my"],html[lang^="km"]) :is(.reel-copy h1,.entry-title) {
    letter-spacing: normal;
    line-height: 1.3;
    font-size: clamp(1.9rem,4.6vw,3.7rem);
}

@media(max-width:1020px) {
    .guide-grid {
        grid-template-columns: repeat(2,minmax(0,1fr));
    }
}

@media(max-width:760px) {
    body {
        padding: 0;
    }
    .shell,.reading-width {
        width: calc(100% - 32px);
    }
    .site-header {
        position: relative;
        width: auto;
        border-right: 0;
        border-bottom: 1px solid var(--line);
    }
    .site-header-inner {
        width: calc(100% - 32px);
        margin-inline: auto;
        padding: .7rem 0;
        display: flex;
        flex-wrap: wrap;
        gap: .35rem .75rem;
    }
    .header-guides {
        margin-inline-start: auto;
    }
    .languages {
        display: flex;
        flex-wrap: wrap;
        width: 100%;
    }
    .reel-hero {
        min-height: 360px;
        align-items: end;
        margin-top: 1rem;
    }
    .reel-hero::before {
        background: linear-gradient(0deg,#171a38 10%,#171a38d9 44%,#171a382a 100%);
    }
    .reel-copy {
        padding: 1.3rem;
    }
    .reel-copy h1 {
        font-size: clamp(2.3rem,10vw,3.4rem);
    }
    .article-mast {
        padding-block: 1.7rem;
    }
    .entry-content table {
        display: block;
        overflow-x: auto;
    }
}

@media(max-width:460px) {
    .guide-grid {
        grid-template-columns: 1fr;
    }
}
