:root {
    --bg: #0b1224;
    --bg-card: #0f182f;
    --bg-elevated: #121c38;
    --text: #eef2ff;
    --muted: #a9b3cf;
    --accent: #6ee7ff;
    --accent-2: #7c3aed;
    --border: rgba(255,255,255,0.08);
    --shadow: 0 18px 50px rgba(0, 0, 0, 0.35);
    --radius: 14px;
    font-family: "Inter", "Segoe UI", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }

body {
    margin: 0;
    padding: 0;
    background: radial-gradient(circle at 20% 20%, rgba(124, 58, 237, 0.12), transparent 35%), radial-gradient(circle at 80% 0%, rgba(110, 231, 255, 0.16), transparent 40%), linear-gradient(145deg, #0a0f1f, #0c1227 55%, #0a0f1f);
    color: var(--text);
    min-height: 100vh;
}

.site-header {
    background: rgba(15, 24, 47, 0.9);
    border-bottom: 1px solid var(--border);
    padding: 1rem 1.2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    backdrop-filter: blur(12px);
    position: sticky;
    top: 0;
    z-index: 10;
}

.site-header h1 {
    margin: 0;
    font-size: 1.4rem;
    letter-spacing: 0.01em;
}

.site-header .logo-title {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.brand-logo {
    height: 26px;
    width: auto;
    display: block;
    filter: drop-shadow(0 6px 12px rgba(0,0,0,0.25));
}

.site-header p {
    margin: 0.25rem 0 0;
    font-size: 0.9rem;
    color: var(--muted);
}

.header-controls {
    display: flex;
    align-items: center;
    gap: 0.6rem;
}

main {
    max-width: 1100px;
    margin: 1.6rem auto 2.4rem;
    padding: 0 1rem;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.stat-card {
    background: linear-gradient(160deg, var(--bg-card), var(--bg-elevated));
    border-radius: var(--radius);
    padding: 1rem 1.2rem;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.stat-label {
    margin: 0;
    font-size: 0.75rem;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--muted);
}

.stat-value {
    margin: 0.4rem 0 0;
    font-size: 1.9rem;
    font-weight: 600;
    color: var(--text);
}

.stat-sub {
    margin: 0.2rem 0 0;
    color: var(--muted);
    font-size: 0.9rem;
}

.stat-list {
    list-style: none;
    margin: 0.5rem 0 0;
    padding: 0;
    font-size: 0.9rem;
    color: var(--text);
}

.stat-list li + li {
    margin-top: 0.3rem;
}

.progress {
    width: 100%;
    height: 10px;
    border-radius: 999px;
    background: rgba(255,255,255,0.08);
    overflow: hidden;
    margin: 0.4rem 0;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, #3ecfff, #7c3aed);
    border-radius: inherit;
}

.chart-bars {
    display: flex;
    align-items: flex-end;
    gap: 0.75rem;
    min-height: 220px;
    margin-top: 1rem;
}

.chart-bar {
    flex: 1;
    background: linear-gradient(180deg, rgba(110, 231, 255, 0.9), rgba(124, 58, 237, 0.8));
    border-radius: 14px 14px 6px 6px;
    position: relative;
    height: var(--bar-value, 10%);
    min-height: 10px;
    box-shadow: 0 8px 18px rgba(0,0,0,0.35);
}

.chart-bar-value {
    position: absolute;
    top: -28px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.78rem;
    color: #cbd5f5;
}

.chart-bar-label {
    position: absolute;
    bottom: -26px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.8rem;
    color: var(--muted);
}

.chart-hint {
    margin-top: 0.8rem;
    font-size: 0.85rem;
    color: var(--muted);
}

.tax-checklist {
    list-style: disc;
    margin-left: 1.2rem;
    color: var(--muted);
}

.tax-checklist li + li {
    margin-top: 0.4rem;
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.2rem;
}

.product-card {
    background: linear-gradient(160deg, var(--bg-card), var(--bg-elevated));
    border-radius: var(--radius);
    padding: 1rem;
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    position: relative;
    overflow: hidden;
}

.product-card::after {
    content: "";
    position: absolute;
    inset: 0;
    background: radial-gradient(circle at 20% 20%, rgba(110, 231, 255, 0.08), transparent 45%), radial-gradient(circle at 80% 10%, rgba(124, 58, 237, 0.08), transparent 40%);
    pointer-events: none;
}

.product-card h2 {
    margin-top: 0;
    font-size: 1.1rem;
}

.product-thumb {
    margin-bottom: 0.8rem;
    border-radius: 10px;
    overflow: hidden;
    text-align: center;
    box-shadow: var(--shadow);
}

.product-card .price {
    font-weight: bold;
    margin: 0.3rem 0 0.6rem;
}

.product-card img,
.product-hero img {
    width: auto;
    max-width: 100%;
    height: 220px;
    display: block;
    margin: 0 auto;
    border-radius: 10px;
    object-fit: contain;
}

.product-detail .price {
    font-weight: bold;
    margin-bottom: 1rem;
}

.product-hero {
    margin: 0 auto 1.2rem;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: var(--shadow);
    max-width: 720px;
}
.product-hero img {
    width: 100%;
    height: auto;
    display: block;
}
.product-hero--logo {
    max-width: 360px;
    padding: 0.5rem;
}
.product-hero--logo img {
    max-height: 160px;
    object-fit: contain;
}

.description {
    margin-bottom: 1rem;
    color: var(--muted);
    line-height: 1.6;
}
.screenshot-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
    gap: 0.8rem;
    margin-bottom: 1.2rem;
}
.screenshot-grid--bundle {
    grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
}
.screenshot-card {
    background: #fff;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    padding: 0.6rem;
    text-align: center;
    box-shadow: 0 6px 20px rgba(15,23,42,0.08);
}
.screenshot-card img {
    max-width: 100%;
    max-height: 110px;
    object-fit: cover;
    border-radius: 8px;
    display: block;
    margin: 0 auto 0.4rem;
}
.screenshot-card figcaption {
    font-size: 0.85rem;
    color: #475569;
}

.btn {
    display: inline-block;
    padding: 0.55rem 1rem;
    border-radius: 999px;
    border: 1px solid var(--border);
    text-decoration: none;
    color: var(--text);
    font-size: 0.92rem;
    background: linear-gradient(135deg, rgba(110, 231, 255, 0.15), rgba(124, 58, 237, 0.18));
    cursor: pointer;
    transition: transform 0.1s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.btn:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.25);
    border-color: rgba(255,255,255,0.25);
}

.btn.primary {
    background: linear-gradient(135deg, #3ecfff, #7c3aed);
    border-color: transparent;
    color: #fff;
}

.btn.small {
    font-size: 0.82rem;
    padding: 0.35rem 0.8rem;
}

.form-card {
    background: linear-gradient(160deg, var(--bg-card), var(--bg-elevated));
    padding: 1rem;
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    border: 1px solid var(--border);
    max-width: 700px;
}

label {
    display: block;
    margin-bottom: 0.6rem;
    font-size: 0.92rem;
}

input[type="text"],
input[type="password"],
textarea,
select {
    width: 100%;
    padding: 0.5rem;
    margin-top: 0.2rem;
    border-radius: 12px;
    border: 1px solid var(--border);
    box-sizing: border-box;
    background: rgba(255,255,255,0.04);
    color: var(--text);
}

select {
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    padding: 0.55rem 2.3rem 0.55rem 0.85rem;
    border: 1px solid rgba(110, 231, 255, 0.35);
    background:
        linear-gradient(135deg, rgba(15, 24, 47, 0.98), rgba(12, 18, 39, 0.94)),
        url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath fill='%23b3e8ff' d='M1 1l4 4 4-4'/%3E%3C/svg%3E") no-repeat right 12px center;
    background-size: auto, 10px 6px;
    box-shadow: 0 6px 16px rgba(10, 15, 31, 0.55);
    cursor: pointer;
}

select:focus {
    outline: none;
    border-color: rgba(110, 231, 255, 0.8);
    box-shadow:
        0 0 0 1px rgba(110, 231, 255, 0.65),
        0 0 0 4px rgba(110, 231, 255, 0.18),
        0 6px 16px rgba(10, 15, 31, 0.55);
}

select option {
    background: #0a0f1f;
    color: #e5e7ff;
}

select option:checked,
select option:focus {
    background: #6ee7ff;
    color: #0a0f1f;
}

select:disabled {
    opacity: 0.55;
    cursor: not-allowed;
}

textarea {
    resize: vertical;
}

fieldset {
    border: 1px solid var(--border);
    border-radius: 10px;
    margin-bottom: 1rem;
    padding: 0.8rem;
}

legend {
    padding: 0 0.4rem;
    font-size: 0.9rem;
    color: var(--muted);
}

.table {
    width: 100%;
    border-collapse: collapse;
    background: linear-gradient(160deg, var(--bg-card), var(--bg-elevated));
    border-radius: var(--radius);
    overflow: hidden;
    box-shadow: var(--shadow);
    color: var(--text);
}

.table th,
.table td {
    padding: 0.6rem 0.7rem;
    border-bottom: 1px solid var(--border);
    font-size: 0.9rem;
}

.table th {
    background: rgba(255,255,255,0.04);
    text-align: left;
}

.error {
    color: #c00;
    background: #ffecec;
    padding: 0.5rem;
    border-radius: 4px;
    margin-bottom: 0.8rem;
}

details summary {
    cursor: pointer;
    font-weight: 600;
    margin: 0.3rem 0;
}

button.linklike {
    border: none;
    background: none;
    padding: 0;
    margin: 0;
    color: #4fa3ff;
    cursor: pointer;
    text-decoration: underline;
    font: inherit;
}

@media (max-width: 600px) {
    .site-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .header-controls {
        width: 100%;
        justify-content: space-between;
    }
}
