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

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

:root {
    --canvas: #f7f7f4;
    --canvas-soft: #fafaf7;
    --surface-card: #ffffff;
    --surface-strong: #e6e5e0;
    --primary: #f54e00;
    --primary-active: #d04200;
    --ink: #26251e;
    --body: #5a5852;
    --body-strong: #26251e;
    --muted: #807d72;
    --muted-soft: #a09c92;
    --on-primary: #ffffff;
    --hairline: #e6e5e0;
    --hairline-soft: #efeee8;
    --hairline-strong: #cfcdc4;
    --semantic-success: #1f8a65;
    --semantic-error: #cf2d56;
    --rounded-xs: 4px;
    --rounded-sm: 6px;
    --rounded-md: 8px;
    --rounded-lg: 12px;
    --rounded-xl: 16px;
    --rounded-pill: 9999px;
}

html { scroll-behavior: smooth; }

body {
    font-family: 'Inter', system-ui, 'Helvetica Neue', Helvetica, Arial, sans-serif;
    background: var(--canvas);
    color: var(--body);
    font-size: 16px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a { color: var(--ink); text-decoration: none; }
a:hover { color: var(--primary); }
img { max-width: 100%; height: auto; display: block; }
code, pre { font-family: 'JetBrains Mono', monospace; }

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

/* NAV */
.site-nav {
    background: var(--canvas);
    border-bottom: 1px solid var(--hairline);
    height: 64px;
    position: sticky;
    top: 0;
    z-index: 100;
}
.site-nav .container {
    display: flex;
    align-items: center;
    height: 100%;
    gap: 32px;
}
.nav-logo {
    font-size: 18px;
    font-weight: 600;
    color: var(--ink);
    letter-spacing: -0.2px;
    flex-shrink: 0;
}
.nav-logo span { color: var(--primary); }
.nav-links {
    display: flex;
    gap: 24px;
    list-style: none;
    margin-left: auto;
}
.nav-links a {
    font-size: 14px;
    font-weight: 500;
    color: var(--body);
    line-height: 1.4;
    transition: color 0.15s;
}
.nav-links a:hover { color: var(--ink); }
.nav-hamburger {
    display: none;
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    margin-left: auto;
    flex-direction: column;
    gap: 5px;
}
.nav-hamburger span {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--ink);
    border-radius: 2px;
    transition: all 0.2s;
}

/* HERO */
.hero {
    padding: 80px 0;
    border-bottom: 1px solid var(--hairline);
}
.hero-label {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.88px;
    text-transform: uppercase;
    color: var(--muted);
    background: var(--surface-strong);
    border-radius: var(--rounded-pill);
    padding: 4px 10px;
    margin-bottom: 24px;
}
.hero h1 {
    font-size: 56px;
    font-weight: 400;
    line-height: 1.1;
    letter-spacing: -1.5px;
    color: var(--ink);
    max-width: 760px;
    margin-bottom: 20px;
}
.hero-sub {
    font-size: 18px;
    color: var(--body);
    line-height: 1.5;
    max-width: 560px;
    margin-bottom: 32px;
}
.hero-meta {
    font-size: 13px;
    color: var(--muted);
}

/* SECTIONS */
.section {
    padding: 80px 0;
}
.section-alt {
    background: var(--surface-card);
    border-top: 1px solid var(--hairline);
    border-bottom: 1px solid var(--hairline);
}
.section-label {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.88px;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 16px;
}
.section-title {
    font-size: 36px;
    font-weight: 400;
    letter-spacing: -0.72px;
    color: var(--ink);
    line-height: 1.2;
    margin-bottom: 16px;
}
.section-sub {
    font-size: 16px;
    color: var(--body);
    max-width: 540px;
    line-height: 1.5;
    margin-bottom: 48px;
}

/* CARDS GRID */
.cards-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
}
.cards-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.card {
    background: var(--surface-card);
    border: 1px solid var(--hairline);
    border-radius: var(--rounded-lg);
    padding: 24px;
    transition: border-color 0.15s;
}
.card:hover { border-color: var(--hairline-strong); }
.card-tag {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.88px;
    text-transform: uppercase;
    color: var(--muted);
    background: var(--surface-strong);
    border-radius: var(--rounded-pill);
    padding: 3px 8px;
    margin-bottom: 12px;
}
.card h3 {
    font-size: 18px;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 8px;
    line-height: 1.3;
}
.card p {
    font-size: 14px;
    color: var(--body);
    line-height: 1.5;
}
.card-img {
    width: 100%;
    height: 200px;
    object-fit: cover;
    border-radius: var(--rounded-md);
    margin-bottom: 16px;
}
.card-link {
    display: inline-block;
    margin-top: 16px;
    font-size: 14px;
    font-weight: 500;
    color: var(--primary);
}
.card-link:hover { color: var(--primary-active); }

/* ARTICLE CARD (list style) */
.article-list { display: flex; flex-direction: column; gap: 0; }
.article-item {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 24px;
    padding: 24px 0;
    border-bottom: 1px solid var(--hairline-soft);
    align-items: start;
}
.article-item:first-child { border-top: 1px solid var(--hairline-soft); }
.article-item img {
    width: 200px;
    height: 130px;
    object-fit: cover;
    border-radius: var(--rounded-md);
    flex-shrink: 0;
}
.article-item-body {}
.article-item-tag {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.88px;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 6px;
}
.article-item h3 {
    font-size: 20px;
    font-weight: 400;
    letter-spacing: -0.11px;
    color: var(--ink);
    margin-bottom: 8px;
    line-height: 1.3;
}
.article-item p {
    font-size: 14px;
    color: var(--body);
    line-height: 1.5;
    margin-bottom: 12px;
}
.article-item-meta {
    font-size: 13px;
    color: var(--muted);
}

/* ARTICLE PAGE */
.article-hero {
    padding: 48px 0 0;
}
.article-hero-img {
    width: 100%;
    max-height: 480px;
    object-fit: cover;
    border-radius: var(--rounded-lg);
    margin-bottom: 48px;
}
.article-layout {
    display: grid;
    grid-template-columns: 1fr 280px;
    gap: 64px;
    padding: 0 0 80px;
}
.article-body h1 {
    font-size: 42px;
    font-weight: 400;
    letter-spacing: -1px;
    color: var(--ink);
    line-height: 1.15;
    margin-bottom: 16px;
}
.article-body .article-meta {
    font-size: 13px;
    color: var(--muted);
    margin-bottom: 32px;
    padding-bottom: 24px;
    border-bottom: 1px solid var(--hairline);
}
.article-body h2 {
    font-size: 26px;
    font-weight: 400;
    letter-spacing: -0.325px;
    color: var(--ink);
    line-height: 1.25;
    margin: 40px 0 16px;
}
.article-body h3 {
    font-size: 20px;
    font-weight: 600;
    color: var(--ink);
    margin: 28px 0 12px;
}
.article-body p {
    font-size: 16px;
    color: var(--body);
    line-height: 1.6;
    margin-bottom: 20px;
    letter-spacing: 0.08px;
}
.article-body ul, .article-body ol {
    margin: 0 0 20px 24px;
    color: var(--body);
    font-size: 16px;
    line-height: 1.6;
}
.article-body li { margin-bottom: 6px; }
.article-body a { color: var(--primary); }
.article-body a:hover { color: var(--primary-active); }

.article-body .info-box {
    background: var(--canvas-soft);
    border: 1px solid var(--hairline);
    border-left: 3px solid var(--primary);
    border-radius: var(--rounded-md);
    padding: 20px 24px;
    margin: 32px 0;
    font-size: 15px;
    color: var(--body-strong);
    line-height: 1.5;
}

.article-body .code-block {
    background: var(--surface-card);
    border: 1px solid var(--hairline);
    border-radius: var(--rounded-lg);
    padding: 20px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    color: var(--ink);
    overflow-x: auto;
    margin: 24px 0;
    line-height: 1.5;
}

.article-body figure {
    margin: 32px 0;
}
.article-body figure img {
    width: 100%;
    border-radius: var(--rounded-lg);
    border: 1px solid var(--hairline);
}
.article-body figcaption {
    font-size: 13px;
    color: var(--muted);
    line-height: 1.4;
    margin-top: 8px;
}

.article-sidebar {}
.sidebar-box {
    background: var(--surface-card);
    border: 1px solid var(--hairline);
    border-radius: var(--rounded-lg);
    padding: 24px;
    margin-bottom: 24px;
}
.sidebar-box h4 {
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.88px;
    text-transform: uppercase;
    color: var(--muted);
    margin-bottom: 16px;
}
.sidebar-box ul { list-style: none; }
.sidebar-box li {
    padding: 8px 0;
    border-bottom: 1px solid var(--hairline-soft);
    font-size: 14px;
}
.sidebar-box li:last-child { border-bottom: none; }
.sidebar-box a { color: var(--body); }
.sidebar-box a:hover { color: var(--primary); }

/* DATA TABLE */
.data-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    margin: 24px 0;
}
.data-table th {
    text-align: left;
    padding: 10px 16px;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.88px;
    text-transform: uppercase;
    color: var(--muted);
    border-bottom: 1px solid var(--hairline);
    background: var(--canvas-soft);
}
.data-table td {
    padding: 12px 16px;
    border-bottom: 1px solid var(--hairline-soft);
    color: var(--body);
    vertical-align: top;
}
.data-table tr:last-child td { border-bottom: none; }

/* FORM */
.contact-section { padding: 80px 0; }
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 80px;
    align-items: start;
}
.contact-form-wrap { }
.form-field { margin-bottom: 20px; }
.form-field label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: var(--ink);
    margin-bottom: 6px;
}
.form-field input,
.form-field textarea {
    width: 100%;
    background: var(--surface-card);
    border: 1px solid var(--hairline-strong);
    border-radius: var(--rounded-md);
    padding: 12px 16px;
    font-size: 16px;
    font-family: inherit;
    color: var(--ink);
    height: 44px;
    transition: border-color 0.15s;
    outline: none;
}
.form-field textarea { height: 120px; resize: vertical; }
.form-field input:focus,
.form-field textarea:focus { border-color: var(--primary); }
.form-field input.error,
.form-field textarea.error { border-color: var(--semantic-error); }
.field-error {
    font-size: 13px;
    color: var(--semantic-error);
    margin-top: 4px;
    display: none;
}
.btn-primary {
    background: var(--primary);
    color: var(--on-primary);
    border: none;
    border-radius: var(--rounded-md);
    padding: 10px 18px;
    height: 40px;
    font-size: 14px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    transition: background 0.15s;
    display: inline-flex;
    align-items: center;
    gap: 8px;
}
.btn-primary:hover { background: var(--primary-active); }
.btn-primary:disabled { opacity: 0.6; cursor: not-allowed; }
.form-success {
    display: none;
    background: var(--canvas-soft);
    border: 1px solid var(--hairline);
    border-left: 3px solid var(--semantic-success);
    border-radius: var(--rounded-md);
    padding: 16px 20px;
    font-size: 15px;
    color: var(--semantic-success);
}

/* FOOTER */
.site-footer {
    background: var(--canvas);
    border-top: 1px solid var(--hairline);
    padding: 64px 0 48px;
}
.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr 1fr;
    gap: 32px;
    margin-bottom: 48px;
}
.footer-brand p {
    font-size: 14px;
    color: var(--body);
    line-height: 1.5;
    margin-top: 12px;
    max-width: 240px;
}
.footer-col h5 {
    font-size: 13px;
    font-weight: 600;
    color: var(--ink);
    margin-bottom: 16px;
}
.footer-col ul { list-style: none; }
.footer-col li { margin-bottom: 10px; }
.footer-col a {
    font-size: 14px;
    color: var(--body);
    transition: color 0.15s;
}
.footer-col a:hover { color: var(--ink); }
.footer-bottom {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 24px;
    border-top: 1px solid var(--hairline-soft);
    font-size: 13px;
    color: var(--muted);
}
.footer-bottom a { color: var(--muted); }
.footer-bottom a:hover { color: var(--body); }

/* COOKIE BANNER */
#cookie-banner {
    position: fixed;
    bottom: 24px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--ink);
    color: var(--canvas);
    border-radius: var(--rounded-lg);
    padding: 20px 24px;
    max-width: 560px;
    width: calc(100% - 48px);
    display: flex;
    gap: 24px;
    align-items: center;
    z-index: 1000;
    box-shadow: none;
}
#cookie-banner p {
    font-size: 14px;
    line-height: 1.5;
    flex: 1;
    color: var(--canvas);
}
#cookie-banner a { color: var(--primary); text-decoration: underline; }
.cookie-actions { display: flex; gap: 8px; flex-shrink: 0; }
.btn-cookie-accept {
    background: var(--primary);
    color: var(--on-primary);
    border: none;
    border-radius: var(--rounded-md);
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    font-family: inherit;
}
.btn-cookie-reject {
    background: transparent;
    color: var(--canvas-soft);
    border: 1px solid rgba(255,255,255,0.25);
    border-radius: var(--rounded-md);
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    white-space: nowrap;
    font-family: inherit;
}
.btn-cookie-accept:hover { background: var(--primary-active); }
.btn-cookie-reject:hover { border-color: rgba(255,255,255,0.5); }

/* PAGE CONTENT (about, privacy, terms) */
.page-content {
    max-width: 760px;
    margin: 0 auto;
    padding: 64px 0 80px;
}
.page-content h1 {
    font-size: 42px;
    font-weight: 400;
    letter-spacing: -1px;
    color: var(--ink);
    margin-bottom: 8px;
}
.page-content .page-meta {
    font-size: 13px;
    color: var(--muted);
    margin-bottom: 40px;
    padding-bottom: 32px;
    border-bottom: 1px solid var(--hairline);
}
.page-content h2 {
    font-size: 22px;
    font-weight: 600;
    color: var(--ink);
    margin: 36px 0 12px;
}
.page-content p {
    font-size: 16px;
    color: var(--body);
    line-height: 1.6;
    margin-bottom: 18px;
}
.page-content ul, .page-content ol {
    margin: 0 0 18px 24px;
    color: var(--body);
    font-size: 16px;
    line-height: 1.6;
}
.page-content li { margin-bottom: 6px; }
.page-content a { color: var(--primary); }

/* DISCLAIMER */
.disclaimer {
    background: var(--canvas-soft);
    border: 1px solid var(--hairline);
    border-radius: var(--rounded-md);
    padding: 16px 20px;
    font-size: 13px;
    color: var(--muted);
    line-height: 1.5;
    margin-top: 32px;
}

/* BREADCRUMB */
.breadcrumb {
    padding: 16px 0;
    font-size: 13px;
    color: var(--muted);
}
.breadcrumb a { color: var(--muted); }
.breadcrumb a:hover { color: var(--body); }
.breadcrumb span { margin: 0 6px; }

/* RESPONSIVE */
@media (max-width: 1024px) {
    .hero h1 { font-size: 44px; }
    .section-title { font-size: 30px; }
    .cards-grid { grid-template-columns: repeat(2, 1fr); }
    .footer-grid { grid-template-columns: 1fr 1fr 1fr; }
    .footer-brand { grid-column: 1 / -1; }
    .article-layout { grid-template-columns: 1fr; gap: 40px; }
    .article-sidebar { display: none; }
    .contact-grid { grid-template-columns: 1fr; gap: 40px; }
}

@media (max-width: 768px) {
    .hero h1 { font-size: 32px; letter-spacing: -0.8px; }
    .hero { padding: 48px 0; }
    .section { padding: 48px 0; }
    .cards-grid { grid-template-columns: 1fr; }
    .cards-grid-2 { grid-template-columns: 1fr; }
    .nav-links { display: none; }
    .nav-hamburger { display: flex; }
    .nav-links.open {
        display: flex;
        flex-direction: column;
        position: absolute;
        top: 64px;
        left: 0;
        right: 0;
        background: var(--canvas);
        border-bottom: 1px solid var(--hairline);
        padding: 16px 24px;
        gap: 16px;
    }
    .site-nav { position: relative; }
    .footer-grid { grid-template-columns: 1fr 1fr; }
    .footer-brand { grid-column: 1 / -1; }
    .footer-bottom { flex-direction: column; gap: 12px; text-align: center; }
    .article-item { grid-template-columns: 1fr; }
    .article-item img { width: 100%; height: 200px; }
    #cookie-banner { flex-direction: column; align-items: stretch; }
    .cookie-actions { justify-content: flex-end; }
    .article-body h1 { font-size: 28px; }
    .page-content h1 { font-size: 28px; }
    .page-content { padding: 32px 0 48px; }
}
