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

:root {
    --bg:      #ffffff;
    --ink:     #000000;
    --accent:  #2563eb;
    --muted:   #6b7280;
    --border:  rgba(0,0,0,0.05);
    --surface: #fafafa;
}

[data-theme="dark"] {
    --bg:      #050505;
    --ink:     #ffffff;
    --accent:  #d9ff00;
    --muted:   #9ca3af;
    --border:  rgba(255,255,255,0.06);
    --surface: #0f0f0f;
}

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

body {
    background: var(--bg);
    color: var(--ink);
    font-family: 'Plus Jakarta Sans', sans-serif;
    padding: 40px 20px;
    transition: background 0.3s, color 0.3s; min-height: 100vh; display: flex; flex-direction: column; align-items: center; }

header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 24px;
    max-width: 1200px;
    margin-left: auto; width: 100%;
    margin-right: auto;
}

.back-link {
    font-family: 'Space Mono', monospace;
    font-size: 1.5rem;
    color: var(--muted);
    text-decoration: none;
    display: inline-block;
    margin-bottom: 20px;
    transition: color 0.2s;
}

.back-link:hover { color: var(--ink); }

.logo {
    font-weight: 800;
    font-size: 2.5rem;
    line-height: 1.1;
}

.tagline {
    font-family: 'Space Mono', monospace;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--muted);
    margin-top: 12px;
}

.theme-toggle {
    background: none;
    border: none;
    color: var(--ink);
    cursor: pointer;
    padding: 8px;
    border-radius: 12px;
    transition: opacity 0.2s;
    flex-shrink: 0;
}

.theme-toggle:hover { opacity: 0.6; }

/* Layout */
.layout {
    max-width: 1200px;
    margin: 0 auto; width: 100%; width: 100%;
    display: grid;
    gap: 24px;
    flex: 1;}

@media (min-width: 900px) {
    .layout {
        grid-template-columns: 1fr 1fr;
        flex: 1;}
    .layout-preview {
        position: sticky;
        top: 40px;
        align-self: start;
    }
}

/* Cards */
.card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 32px;
    padding: 28px;
    margin-bottom: 20px;
}

.hidden { display: none; }

.label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 10px;
    text-transform: uppercase;
    font-weight: 700;
    display: block;
    margin-bottom: 12px;
}

/* Output split layout */
.output-split {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.output-split > .card {
    flex: 1;
    min-width: 0;
}

/* Inputs */
.input {
    width: 100%;
    background: var(--bg);
    color: var(--ink);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 14px 16px;
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.95rem;
    transition: border-color 0.2s;
}

.input:focus {
    outline: none;
    border-color: var(--accent);
}

.input--select {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 36px;
    cursor: pointer;
}

.row { display: flex; gap: 10px; align-items: center; }
.row--mt { margin-top: 12px; }

.color-field { display: flex; flex-direction: column; gap: 4px; flex: 1; }
.select-field { flex: 1; display: flex; flex-direction: column; gap: 4px; }

.color-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 9px;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--muted);
}

.color-picker {
    width: 100%;
    height: 36px;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 2px;
    background: var(--bg);
    cursor: pointer;
}

.color-picker::-webkit-color-swatch-wrapper { padding: 0; }
.color-picker::-webkit-color-swatch { border: none; border-radius: 6px; }

/* Buttons */
.btn {
    background: var(--ink);
    color: var(--bg);
    border: none;
    border-radius: 12px;
    padding: 14px 24px;
    font-weight: 700;
    font-size: 0.85rem;
    cursor: pointer;
    transition: opacity 0.2s;
    text-align: center;
    font-family: 'Plus Jakarta Sans', sans-serif;
}

.btn:hover { opacity: 0.8; }
.btn:disabled { opacity: 0.3; cursor: default; }

.btn--outline {
    background: transparent;
    color: var(--ink);
    border: 1px solid var(--border);
}

.btn--small {
    padding: 8px 16px;
    font-size: 0.75rem;
}

/* Mode panels */
.mode-panel { display: block; }

/* Collapsible card */
.collapse-toggle {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    background: none;
    border: none;
    color: var(--ink);
    cursor: pointer;
    padding: 0;
    font-family: inherit;
}

.collapse-toggle .label {
    margin-bottom: 0;
}



.collapse-icon {
    font-size: 1.4rem;
    line-height: 1;
    transition: transform 0.2s;
}

.collapse-toggle[aria-expanded="false"] .collapse-icon {
    transform: rotate(-90deg);
}

.collapse-body {
    overflow: hidden;
    transition: max-height 0.25s ease, opacity 0.2s ease;
    max-height: 600px;
    opacity: 1;}

.collapse-toggle[aria-expanded="false"] + .collapse-body {
    max-height: 0;
    opacity: 0;
    padding-top: 0;
    padding-bottom: 0;}

/* Upload zone */
.upload-zone {
    min-height: 200px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color 0.2s;
}

.upload-zone:hover {
    border-color: var(--accent);
}

.upload-placeholder {
    text-align: center;
    color: var(--muted);
}

.upload-text {
    font-size: 0.85rem;
    margin-top: 12px;
}

.upload-preview {
    text-align: center;
}

.upload-preview img {
    max-width: 120px;
    max-height: 120px;
    border-radius: 12px;
    border: 1px solid var(--border);
    image-rendering: pixelated;
}

/* Icon panel preview */
.icon-preview-box {
    margin-top: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 20px;
    min-height: 80px;
}

.icon-preview-symbol {
    font-size: 48px !important;
    color: var(--ink);
}

/* Browser tab preview */
.browser-tab {
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
}

.browser-bar {
    background: var(--bg);
    padding: 10px 14px;
    display: flex;
    align-items: center;
    gap: 6px;
    border-bottom: 1px solid var(--border);
}

.browser-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--border);
}

.browser-url {
    font-size: 0.7rem;
    color: var(--muted);
    margin-left: 8px;
    font-family: 'JetBrains Mono', monospace;
}

.browser-content {
    padding: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
    background: var(--bg);
}

.tab-favicon {
    width: 20px;
    height: 20px;
    border-radius: 3px;
    image-rendering: pixelated;
}

.tab-title {
    font-size: 0.9rem;
    font-weight: 600;
}

/* Icon grid */
.output-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
    gap: 12px;
    flex-wrap: wrap;
}

.icon-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
}

.icon-card {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 14px 10px 10px;
    text-align: center;
    transition: border-color 0.2s;
}

.icon-card:hover {
    border-color: var(--accent);
}

.icon-card .icon-preview {
    width: 48px;
    height: 48px;
    margin: 0 auto 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--surface);
    border-radius: 10px;
    border: 1px solid var(--border);
}

.icon-card img {
    max-width: 48px;
    max-height: 48px;
    image-rendering: pixelated;
    border-radius: 4px;
}

.icon-card .ico-label {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.6rem;
    font-weight: 700;
    color: var(--muted);
}

.icon-card .icon-name {
    font-weight: 600;
    font-size: 0.65rem;
    word-break: break-all;
    line-height: 1.2;
    margin-bottom: 2px;
}

.icon-card .icon-size {
    font-family: 'JetBrains Mono', monospace;
    font-size: 0.55rem;
    color: var(--muted);
    margin-bottom: 8px;
}

.icon-card .btn--small {
    font-size: 0.6rem;
    padding: 6px 12px;
    width: 100%;
}

/* Footer */

.footer {
    font-family: 'Space Mono', monospace;
    font-size: 8px;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-weight: 700;
        margin: 96px auto 0;
    padding: 24px 0 0;
    border-top: 1px solid var(--border);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-align: center;
    color: var(--muted);
    line-height: 1.6;
        max-width: 1200px;
}

.footer a {
    color: inherit;
    text-decoration: underline;
    text-underline-offset: 2px;
}

.footer-inner {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

@media (min-width: 640px) {
    .footer {
        flex-direction: row;
        justify-content: space-between;
            max-width: 1200px;
}
    .footer-inner {
        flex-direction: row;
        gap: 4px;
    }
}

@media (min-width: 768px) {
    body { padding: 60px 40px; }
}

@media (min-width: 1024px) {
    body { padding: 60px 80px; }
}













