/* ─────────────────────────────────────────────────────────
   Diarium Plugin Shop — Light Editorial Theme (v2026.2)
───────────────────────────────────────────────────────── */

@import url('https://fonts.googleapis.com/css2?family=Fraunces:opsz,wght@9..144,400;9..144,500;9..144,600;9..144,700;9..144,800;9..144,900&family=JetBrains+Mono:wght@400;500;700&family=Inter:wght@400;500;600&display=swap');

:root {
    --bg: #ffffff;
    --bg-elev: #f8fafc;
    --bg-card: #ffffff;
    --border: #e2e8f0;
    --border-light: #cbd5e1;
    --text: #0f172a;
    --text-dim: #475569;
    --text-faint: #94a3b8;
    --gold: #b48554;
    --gold-bright: #d4a574;
    --teal: #0d9488;
    --rose: #e11d48;
    --serif: 'Fraunces', Georgia, serif;
    --mono: 'JetBrains Mono', 'SF Mono', Consolas, monospace;
    --sans: 'Inter', -apple-system, sans-serif;
}

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

html { scroll-behavior: smooth; }

body {
    background: var(--bg);
    color: var(--text);
    font-family: var(--sans);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    overflow-x: hidden;
}

/* Background grain texture - Subtle on light */
body::before {
    content: '';
    position: fixed;
    inset: 0;
    pointer-events: none;
    opacity: 0.04;
    z-index: 100;
    background-image:
        radial-gradient(circle at 1px 1px, #000 1px, transparent 0);
    background-size: 8px 8px;
    mix-blend-mode: multiply;
}

/* Decorative gradient orbs */
body::after {
    content: '';
    position: fixed;
    top: -200px;
    right: -200px;
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(180, 133, 84, 0.08) 0%, transparent 70%);
    pointer-events: none;
    z-index: -1;
}

a { color: var(--gold); text-decoration: none; transition: color 0.2s; }
a:hover { color: var(--gold-bright); }

/* ───── Layout ───── */
.container {
    max-width: 1240px;
    margin: 0 auto;
    padding: 0 32px;
}

.container-narrow {
    max-width: 860px;
    margin: 0 auto;
    padding: 0 32px;
}

/* ───── Header ───── */
.site-header {
    border-bottom: 1px solid var(--border);
    padding: 24px 0;
    position: sticky;
    top: 0;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    z-index: 50;
}

.site-header-inner {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo {
    font-family: var(--serif);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text);
    letter-spacing: -0.02em;
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-mark {
    width: 32px;
    height: 32px;
    background: linear-gradient(135deg, var(--gold), var(--gold-bright));
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 900;
    font-size: 1rem;
}

.nav {
    display: flex;
    gap: 32px;
    align-items: center;
}

.nav a {
    color: var(--text-dim);
    font-size: 0.875rem;
    font-weight: 500;
    letter-spacing: 0.01em;
}

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

/* ───── Hero ───── */
.hero {
    padding: 120px 0 80px;
    position: relative;
    overflow: hidden;
}

.hero-eyebrow {
    font-family: var(--mono);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--gold);
    margin-bottom: 24px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.hero-eyebrow::before {
    content: '';
    width: 32px;
    height: 1px;
    background: var(--gold);
}

.hero h1 {
    font-family: var(--serif);
    font-size: clamp(3rem, 8vw, 6.5rem);
    font-weight: 500;
    line-height: 0.95;
    letter-spacing: -0.04em;
    margin-bottom: 32px;
    color: var(--text);
}

.hero h1 em {
    font-style: italic;
    font-weight: 400;
    color: var(--gold);
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-dim);
    max-width: 680px;
    margin-bottom: 48px;
    line-height: 1.5;
}

.hero-meta {
    display: flex;
    gap: 48px;
    padding: 24px 0;
    border-top: 1px solid var(--border);
    margin-top: 48px;
}

.hero-meta-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.hero-meta-num {
    font-family: var(--serif);
    font-size: 2rem;
    font-weight: 700;
    color: var(--gold);
    line-height: 1;
}

.hero-meta-label {
    font-family: var(--mono);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--text-faint);
}

/* ───── Section ───── */
.section {
    padding: 100px 0;
    border-top: 1px solid var(--border);
}

.section-header {
    margin-bottom: 64px;
    display: flex;
    justify-content: space-between;
    align-items: end;
    gap: 32px;
    flex-wrap: wrap;
}

.section-eyebrow {
    font-family: var(--mono);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--gold);
    margin-bottom: 12px;
}

.section h2 {
    font-family: var(--serif);
    font-size: clamp(2rem, 5vw, 3.5rem);
    font-weight: 500;
    line-height: 1;
    letter-spacing: -0.03em;
    color: var(--text);
}

.section h2 em {
    font-style: italic;
    color: var(--gold);
}

.section-intro {
    color: var(--text-dim);
    max-width: 420px;
    font-size: 1rem;
    line-height: 1.5;
}

/* ───── Plugin grid ───── */
.plugin-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
    gap: 24px;
}

.plugin-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 32px;
    position: relative;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
    box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

.plugin-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 1px;
    background: linear-gradient(90deg, transparent, var(--gold), transparent);
    opacity: 0;
    transition: opacity 0.3s;
}

.plugin-card:hover {
    border-color: var(--gold);
    transform: translateY(-4px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

.plugin-card:hover::before { opacity: 1; }

.plugin-card-icon {
    font-size: 2rem;
    margin-bottom: 24px;
    display: inline-block;
    width: 56px;
    height: 56px;
    background: var(--bg-elev);
    border: 1px solid var(--border);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.plugin-card-num {
    position: absolute;
    top: 24px;
    right: 24px;
    font-family: var(--mono);
    font-size: 0.7rem;
    color: var(--text-faint);
    letter-spacing: 0.1em;
}

.plugin-card h3 {
    font-family: var(--serif);
    font-size: 1.625rem;
    font-weight: 600;
    line-height: 1.1;
    letter-spacing: -0.02em;
    margin-bottom: 12px;
    color: var(--text);
}

.plugin-card p {
    color: var(--text-dim);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 24px;
    flex: 1;
}

.plugin-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 24px;
    border-top: 1px solid var(--border);
    margin-top: auto;
}

.plugin-card-price {
    font-family: var(--serif);
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--gold);
}

.plugin-card-link {
    font-family: var(--mono);
    font-size: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--text);
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: gap 0.2s;
}

.plugin-card-link:hover {
    color: var(--gold);
}

.plugin-card-link::after {
    content: '→';
    font-size: 1rem;
}

/* ───── Buttons ───── */
.btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    border-radius: 8px;
    font-family: var(--sans);
    font-weight: 600;
    font-size: 0.9rem;
    border: none;
    cursor: pointer;
    transition: all 0.2s;
    text-decoration: none;
}

.btn-primary {
    background: var(--gold);
    color: #fff;
}

.btn-primary:hover {
    background: var(--gold-bright);
    color: #fff;
    transform: translateY(-2px);
    box-shadow: 0 12px 32px rgba(180, 133, 84, 0.2);
}

.btn-secondary {
    background: transparent;
    color: var(--text);
    border: 1px solid var(--border-light);
}

.btn-secondary:hover {
    border-color: var(--gold);
    color: var(--gold);
}

.btn-large {
    padding: 20px 40px;
    font-size: 1rem;
}

/* ───── Footer ───── */
.site-footer {
    border-top: 1px solid var(--border);
    padding: 64px 0 32px;
    margin-top: 80px;
    background: var(--bg-elev);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr;
    gap: 64px;
    margin-bottom: 48px;
}

.footer-brand h3 {
    font-family: var(--serif);
    font-size: 1.5rem;
    margin-bottom: 12px;
    color: var(--text);
}

.footer-brand p {
    color: var(--text-dim);
    font-size: 0.9rem;
    max-width: 360px;
}

.footer-col h4 {
    font-family: var(--mono);
    font-size: 0.7rem;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    color: var(--gold);
    margin-bottom: 16px;
}

.footer-col ul {
    list-style: none;
}

.footer-col ul li {
    margin-bottom: 10px;
}

.footer-col a {
    color: var(--text-dim);
    font-size: 0.875rem;
}

.footer-col a:hover { color: var(--gold); }

.footer-bottom {
    border-top: 1px solid var(--border);
    padding-top: 32px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: var(--text-faint);
    font-size: 0.8rem;
    font-family: var(--mono);
}

/* ───── Responsive ───── */
@media (max-width: 768px) {
    .container, .container-narrow { padding: 0 20px; }
    .nav { display: none; }
    .hero { padding: 64px 0 48px; }
    .hero-meta { flex-direction: column; gap: 24px; }
    .section { padding: 64px 0; }
    .footer-grid { grid-template-columns: 1fr; gap: 40px; }
}

/* ───── Animations ───── */
@keyframes fadeUp {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.hero h1, .hero p, .hero-eyebrow, .hero-meta {
    animation: fadeUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) both;
}

.hero-eyebrow { animation-delay: 0.05s; }
.hero h1 { animation-delay: 0.15s; }
.hero p { animation-delay: 0.3s; }
.hero-meta { animation-delay: 0.5s; }

.plugin-card {
    animation: fadeUp 0.6s cubic-bezier(0.16, 1, 0.3, 1) both;
}