/* ============================================
   Chugger Games — Main Stylesheet
   Accessible palette based on "Friendly Mug"
   ============================================ */

:root {
    /* Core palette */
    --butter-yellow: #FFEAA7;
    --sunshine:      #FFD93D;
    --terracotta:    #C45E3C;
    --sky-blue:      #3D8FB5;
    --deep-roast:    #2D1A0E;
    --cream:         #FFF9F0;

    /* Semantic aliases */
    --color-bg:      var(--cream);
    --color-text:    var(--deep-roast);
    --color-accent:  var(--terracotta);
    --color-cta:     var(--sunshine);
    --color-info:    var(--sky-blue);

    /* Spacing */
    --section-pad: clamp(3rem, 8vw, 6rem) clamp(1.25rem, 5vw, 3rem);
    --content-max: 960px;
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    background-color: var(--color-bg);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='200' height='200'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.25'/%3E%3C/svg%3E");
    color: var(--color-text);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
}

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

a {
    color: var(--color-accent);
    text-decoration: none;
}

a:hover,
a:focus {
    text-decoration: underline;
}

/* ── Dividers ── */
.divider {
    border: none;
    height: 2px;
    background: var(--sky-blue);
    max-width: var(--content-max);
    margin: 0 auto;
    opacity: 0.3;
}

/* ── Utility ── */
.container {
    max-width: var(--content-max);
    margin: 0 auto;
    width: 100%;
}

/* ── Hero ── */
.hero {
    color: var(--deep-roast);
    padding: var(--section-pad);
    min-height: 80vh;
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.hero__content {
    max-width: 700px;
}

.hero__logo {
    font-size: clamp(2.5rem, 8vw, 4.5rem);
    font-weight: 900;
    letter-spacing: 0.06em;
    line-height: 1.1;
    margin-bottom: 0.25em;
}

.hero__logo-accent {
    color: var(--terracotta);
}

.hero__tagline {
    font-size: clamp(1rem, 2.5vw, 1.35rem);
    color: var(--sky-blue);
    margin-bottom: 2rem;
    line-height: 1.5;
}

.hero__cta {
    display: inline-block;
    background: var(--terracotta);
    color: var(--cream);
    font-size: 1rem;
    font-weight: 700;
    padding: 0.75rem 2rem;
    border-radius: 50px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.hero__cta:hover,
.hero__cta:focus {
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

/* ── About ── */
.about {
    padding: var(--section-pad);
}

.about__inner {
    max-width: var(--content-max);
    margin: 0 auto;
}

.section-heading {
    font-size: clamp(1.5rem, 4vw, 2rem);
    font-weight: 800;
    margin-bottom: 1.25rem;
    position: relative;
    display: inline-block;
}

.section-heading::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--terracotta);
    border-radius: 2px;
    margin-top: 0.5rem;
}

.about__text {
    font-size: clamp(1rem, 2vw, 1.125rem);
    max-width: 640px;
    line-height: 1.7;
    color: var(--color-text);
}

/* ── Games ── */
.games {
    padding: var(--section-pad);
}

.games__inner {
    max-width: var(--content-max);
    margin: 0 auto;
}

.games__grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.game-card {
    background: white;
    border-radius: 16px;
    overflow: hidden;
    border: 2px solid var(--sky-blue);
    box-shadow: 0 2px 12px rgba(0, 0, 0, 0.06);
    display: flex;
    flex-direction: column;
    transition: transform 0.2s, box-shadow 0.2s;
}

.game-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.game-card__banner {
    height: 8px;
}

.game-card__banner--terracotta { background: var(--terracotta); }
.game-card__banner--sky-blue   { background: var(--sky-blue); }
.game-card__banner--sunshine   { background: var(--sunshine); }

.game-card__body {
    padding: 1.5rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.game-card__title {
    font-size: 1.25rem;
    font-weight: 800;
    margin-bottom: 0.25rem;
    color: var(--deep-roast);
}

.game-card__status {
    display: inline-block;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.08em;
    padding: 0.2rem 0.6rem;
    border-radius: 20px;
    margin-bottom: 0.75rem;
    width: fit-content;
}

.game-card__status--released {
    background: #D4EDDA;
    color: #1A5C2A;
}

.game-card__status--dev {
    background: #CCE5FF;
    color: #004085;
}

.game-card__desc {
    font-size: 0.925rem;
    line-height: 1.6;
    color: var(--deep-roast);
    flex: 1;
    margin-bottom: 1.25rem;
}

.game-card__link {
    display: inline-block;
    background: var(--terracotta);
    color: var(--cream);
    font-size: 0.875rem;
    font-weight: 700;
    padding: 0.6rem 1.4rem;
    border-radius: 50px;
    transition: transform 0.2s, box-shadow 0.2s;
    align-self: flex-start;
}

.game-card__link:hover,
.game-card__link:focus {
    text-decoration: none;
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

/* ── Footer ── */
.footer {
    color: var(--deep-roast);
    border-top: 3px solid var(--terracotta);
    padding: clamp(2rem, 5vw, 3rem) clamp(1.25rem, 5vw, 3rem);
    text-align: center;
}

.footer__contact {
    margin-bottom: 1rem;
}

.footer__email {
    color: var(--terracotta);
    font-weight: 700;
    font-size: 1.1rem;
}

.footer__email:hover,
.footer__email:focus {
    color: var(--deep-roast);
}

.footer__copy {
    font-size: 0.8rem;
    opacity: 0.6;
}

/* ── Responsive ── */
@media (max-width: 768px) {
    .hero {
        min-height: 60vh;
    }

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