:root {
    --color-orange: #ff6b21;
    --color-orange-dark: #e05510;
    --color-orange-light: #ff8a4d;
    --color-cream: #f9f1e7;
    --color-cream-dark: #ede4d6;
    --color-ink: #1a1a1a;
    --color-ink-muted: #4a4a4a;
    --color-ink-soft: #6a6a6a;
    --color-surface: #fffaf4;
    --color-card: #f5ede3;
    --color-border: #dccfbe;
    --font-display: 'Fredoka', 'Arial Rounded MT Bold', 'Helvetica Rounded', sans-serif;
    --font-body: 'Georgia', 'Times New Roman', serif;
    --shadow-soft: 0 4px 16px rgba(26, 26, 26, 0.08);
    --shadow-card: 0 6px 20px rgba(26, 26, 26, 0.1);
}

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

html {
    -webkit-text-size-adjust: 100%;
    text-size-adjust: 100%;
    overflow-x: hidden;
}

body {
    font-family: var(--font-body);
    line-height: 1.7;
    color: var(--color-ink);
    background: var(--color-ink);
    background-image:
        radial-gradient(circle at 15% 20%, rgba(255, 107, 33, 0.15) 0%, transparent 45%),
        radial-gradient(circle at 85% 80%, rgba(249, 241, 231, 0.08) 0%, transparent 40%);
    min-height: 100vh;
    padding: 20px;
}

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

.container {
    max-width: 1100px;
    margin: 0 auto;
    background: var(--color-surface);
    border-radius: 12px;
    box-shadow: var(--shadow-soft);
    overflow: hidden;
    border: 2px solid var(--color-border);
}

/* Header */
header {
    background: var(--color-ink);
    color: var(--color-cream);
    padding: 36px 40px 44px;
    text-align: center;
    position: relative;
    border-bottom: 4px solid var(--color-orange);
}

header::after {
    content: '';
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 12px;
    background:
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 1200 24' preserveAspectRatio='none'%3E%3Cpath fill='%23ff6b21' d='M0 12 Q150 0 300 12 T600 12 T900 12 T1200 12 V24 H0Z'/%3E%3Cpath fill='%23f9f1e7' d='M0 16 Q150 6 300 16 T600 16 T900 16 T1200 16 V24 H0Z'/%3E%3C/svg%3E")
        center bottom / 100% 100% no-repeat;
}

.header-brand {
    display: inline-block;
    text-decoration: none;
    line-height: 0;
}

.header-logo {
    width: min(420px, 90vw);
    max-width: min(420px, 90vw);
    height: auto;
    display: block;
    margin: 0 auto 16px;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.4));
}

header h1 {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.tagline {
    font-family: var(--font-display);
    /* ~1/8 of rendered logo height (1536×1024 asset at min(420px, 90vw) wide) */
    font-size: calc(min(420px, 90vw) * 1024 / 1536 / 8);
    font-style: italic;
    opacity: 0.92;
    color: var(--color-cream);
    position: relative;
    z-index: 1;
    line-height: 1.45;
    text-align: center;
}

.tagline-creature-slot {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    vertical-align: bottom;
    overflow: hidden;
    position: relative;
    margin: 0 0.1em;
    line-height: 1.45em;
    height: 1.45em;
}

.tagline-creature {
    display: inline-block;
    color: var(--color-orange);
    font-weight: 600;
    font-style: normal;
    text-shadow:
        0 0 10px rgba(255, 107, 33, 0.75),
        0 0 22px rgba(255, 107, 33, 0.35);
    padding: 0 0.2em;
    will-change: transform, opacity;
}

.tagline-creature-exit {
    animation: tagline-creature-out 0.5s ease-in forwards;
}

.tagline-creature-enter {
    animation: tagline-creature-in 0.5s ease-out forwards;
}

@keyframes tagline-creature-out {
    0% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
    100% {
        opacity: 0;
        transform: translateY(-120%) scale(0.75) rotate(-8deg);
        filter: blur(2px);
    }
}

@keyframes tagline-creature-in {
    0% {
        opacity: 0;
        transform: translateY(120%) scale(0.75) rotate(8deg);
        filter: blur(2px);
    }
    70% {
        transform: translateY(-8%) scale(1.08) rotate(0deg);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
        filter: blur(0);
    }
}

.nav-menu {
    margin-top: 24px;
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 12px 20px;
    position: relative;
    z-index: 1;
}

.nav-menu a {
    color: var(--color-cream);
    text-decoration: none;
    font-family: var(--font-display);
    font-size: 1.05em;
    font-weight: 500;
    padding: 8px 16px;
    border-radius: 999px;
    border: 2px solid transparent;
    transition: color 0.2s ease, border-color 0.2s ease, background 0.2s ease;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--color-orange);
    border-color: var(--color-orange);
    background: rgba(255, 107, 33, 0.1);
}

/* Main content */
main {
    padding: 48px 40px;
    background: var(--color-surface);
}

.burnt-toast-theory {
    max-width: 720px;
    margin: 0 auto 48px;
    padding: 24px 28px;
    background: var(--color-card);
    border: 2px solid var(--color-border);
    border-left: 4px solid var(--color-orange);
    border-radius: 8px;
    text-align: center;
}

.burnt-toast-theory p {
    margin: 0;
    font-size: 1.08em;
    line-height: 1.75;
    color: var(--color-ink);
}

.burnt-toast-theory strong {
    color: var(--color-orange-dark);
}

.section {
    margin-bottom: 56px;
    padding-bottom: 48px;
    border-bottom: 2px solid var(--color-border);
}

.section:last-of-type {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.section h2 {
    font-family: var(--font-display);
    color: var(--color-orange);
    font-size: 2em;
    margin-bottom: 24px;
    text-align: center;
    font-weight: 600;
    letter-spacing: 0.5px;
    position: relative;
    padding-bottom: 14px;
}

.section h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 72px;
    height: 3px;
    background: linear-gradient(to right, transparent, var(--color-orange), transparent);
    border-radius: 2px;
}

.section-intro {
    text-align: center;
    color: var(--color-ink-muted);
    font-size: 1.1em;
    max-width: 640px;
    margin: 0 auto 32px;
}

/* About section */
.about-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 32px;
    align-items: start;
    max-width: 900px;
    margin: 0 auto;
}

.about-text p {
    margin-bottom: 16px;
    font-size: 1.05em;
    color: var(--color-ink);
}

.about-text h3 {
    font-family: var(--font-display);
    color: var(--color-orange);
    font-size: 1.35em;
    margin: 24px 0 12px;
}

.about-text a {
    color: var(--color-orange-dark);
    text-decoration: none;
    border-bottom: 1px dotted var(--color-orange);
}

.about-text a:hover {
    color: var(--color-orange);
}

.highlight-box {
    background: var(--color-card);
    border: 2px solid var(--color-border);
    border-left: 4px solid var(--color-orange);
    border-radius: 8px;
    padding: 20px 24px;
    margin: 20px 0;
}

.highlight-box p {
    margin: 0;
}

.about-image {
    width: 100%;
    border-radius: 8px;
    border: 2px solid var(--color-border);
    box-shadow: var(--shadow-card);
}

/* Products */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 28px;
    max-width: 1100px;
    margin: 0 auto;
}

.product-card {
    background: var(--color-card);
    border: 2px solid var(--color-border);
    border-radius: 12px;
    padding: 32px 28px;
    text-align: center;
    transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.product-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-card);
    border-color: var(--color-orange);
}

.product-logo {
    max-height: 72px;
    width: auto;
    max-width: 100%;
    object-fit: contain;
    margin-bottom: 20px;
}

.product-card h3 {
    position: absolute;
    width: 1px;
    height: 1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
}

.product-description {
    color: var(--color-ink-muted);
    font-size: 1.02em;
    line-height: 1.65;
    margin-bottom: 24px;
    flex: 1;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 12px 28px;
    text-decoration: none;
    border-radius: 999px;
    font-family: var(--font-display);
    font-weight: 600;
    font-size: 1em;
    transition: background 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
    border: 2px solid var(--color-orange-dark);
    cursor: pointer;
}

.btn-primary {
    background: var(--color-orange);
    color: var(--color-cream);
}

.btn-primary:hover {
    background: var(--color-orange-light);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(255, 107, 33, 0.35);
}

/* Footer */
footer {
    background: var(--color-ink);
    color: var(--color-cream);
    text-align: center;
    padding: 28px 20px;
    font-size: 0.92em;
    border-top: 4px solid var(--color-orange);
}

footer a {
    color: var(--color-cream);
    text-decoration: none;
    border-bottom: 1px dotted var(--color-cream);
    transition: color 0.2s ease, border-color 0.2s ease;
}

footer a:hover {
    color: var(--color-orange);
    border-bottom-color: var(--color-orange);
}

.footer-links {
    margin-top: 12px;
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px 20px;
}

/* Responsive */
@media (max-width: 768px) {
    body {
        padding: 12px;
    }

    header {
        padding: 28px 20px 40px;
    }

    main {
        padding: 32px 20px;
    }

    .about-grid,
    .products-grid {
        grid-template-columns: 1fr;
        gap: 24px;
    }

    .section h2 {
        font-size: 1.65em;
    }

    .burnt-toast-theory {
        margin-bottom: 36px;
        padding: 20px;
    }
}

@media (max-width: 480px) {
    body {
        padding: 8px;
    }

    header {
        padding: 24px 16px 36px;
    }

    main {
        padding: 24px 16px;
    }

    .product-card {
        padding: 24px 20px;
    }
}

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

    .product-card:hover,
    .btn-primary:hover {
        transform: none;
    }

    .tagline-creature-exit,
    .tagline-creature-enter {
        animation: none;
    }
}
