/* ==================================================================
   Privacy Policy Generator — Styles
   Theme: Dark + Amber Gold palette
   Primary: #FDCB6E | Secondary: #FFEAA7 | Accent: #6C5CE7 | BG: #1A150A
   ================================================================== */

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

:root {
    --primary: #FDCB6E;
    --primary-rgb: 253, 203, 110;
    --secondary: #FFEAA7;
    --accent: #6C5CE7;
    --accent-rgb: 108, 92, 231;
    --bg: #1A150A;
    --bg-card: rgba(26, 21, 10, 0.85);
    --bg-elevated: rgba(40, 32, 16, 0.6);
    --text: #F5F0E5;
    --text-muted: #BDB5A1;
    --text-dim: #8A7F6B;
    --border: rgba(253, 203, 110, 0.12);
    --border-hover: rgba(253, 203, 110, 0.3);
    --danger: #EF4444;
    --radius: 12px;
    --radius-sm: 8px;
    --font: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font);
    background: var(--bg);
    color: var(--text);
    min-height: 100vh;
    line-height: 1.6;
    overflow-x: hidden;
}

.ambient-glow {
    position: fixed;
    border-radius: 50%;
    filter: blur(130px);
    opacity: 0.08;
    pointer-events: none;
    z-index: 0;
}

.glow-1 {
    width: 500px;
    height: 500px;
    background: var(--primary);
    top: -200px;
    right: -100px;
}

.glow-2 {
    width: 400px;
    height: 400px;
    background: var(--accent);
    bottom: -150px;
    left: -100px;
}

.glass-card {
    background: var(--bg-card);
    backdrop-filter: blur(16px);
    -webkit-backdrop-filter: blur(16px);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 1.5rem;
    transition: border-color var(--transition), box-shadow var(--transition);
}

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

.app-container {
    max-width: 720px;
    margin: 0 auto;
    padding: 1.5rem 1rem;
    position: relative;
    z-index: 1;
}

/* ── Header ──────────────────────────────────────────────────── */
.app-header {
    text-align: center;
    margin-bottom: 1.5rem;
}

.logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.logo-icon {
    font-size: 1.75rem;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.tagline {
    font-size: 0.8rem;
    color: var(--text-dim);
}

/* ── Progress ────────────────────────────────────────────────── */
.progress-wrap {
    margin-bottom: 1.5rem;
}

.progress-bar {
    width: 100%;
    height: 4px;
    background: var(--bg-elevated);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--primary), var(--accent));
    border-radius: 4px;
    transition: width 0.4s ease;
}

.progress-text {
    font-size: 0.7rem;
    color: var(--text-dim);
    text-align: center;
    margin-top: 0.5rem;
}

/* ── Steps ────────────────────────────────────────────────────── */
.step {
    display: none;
    animation: fadeIn 0.3s ease;
}

.step.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(8px)
    }

    to {
        opacity: 1;
        transform: translateY(0)
    }
}

.step-title {
    font-size: 1.15rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--primary);
}

.step-desc {
    font-size: 0.85rem;
    color: var(--text-muted);
    margin-bottom: 1rem;
}

/* ── Fields ──────────────────────────────────────────────────── */
.field-group {
    margin-bottom: 1rem;
}

.field-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-bottom: 0.375rem;
}

.required {
    color: var(--primary);
}

.field-input {
    width: 100%;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text);
    font-family: var(--font);
    font-size: 0.9rem;
    padding: 0.6rem 0.75rem;
    transition: border-color var(--transition);
}

.field-input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(var(--primary-rgb), 0.1);
}

.field-input::placeholder {
    color: var(--text-dim);
}

select.field-input {
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' fill='%238A7F6B' viewBox='0 0 16 16'%3E%3Cpath d='M8 11L3 6h10l-5 5z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 0.6rem center;
    padding-right: 1.75rem;
    cursor: pointer;
}

/* ── Checkbox & Radio Grid ───────────────────────────────────── */
.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 0.5rem;
    margin-top: 0.5rem;
}

.checkbox-grid.compact {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
}

.checkbox-item,
.radio-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-muted);
    padding: 0.5rem 0.75rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: border-color var(--transition), color var(--transition);
}

.checkbox-item:hover,
.radio-item:hover {
    border-color: var(--border-hover);
    color: var(--text);
}

.checkbox-item input,
.radio-item input {
    accent-color: var(--primary);
}

.radio-group {
    display: flex;
    gap: 0.75rem;
    margin-top: 0.25rem;
}

/* ── Nav Row ─────────────────────────────────────────────────── */
.nav-row {
    display: flex;
    justify-content: space-between;
    margin-top: 1.25rem;
}

.nav-btn {
    padding: 0.65rem 1.5rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-family: var(--font);
    font-size: 0.875rem;
    font-weight: 500;
    cursor: pointer;
    transition: border-color var(--transition), color var(--transition);
}

.nav-btn:disabled {
    opacity: 0.35;
    cursor: not-allowed;
}

.nav-btn:not(:disabled):hover {
    border-color: var(--border-hover);
    color: var(--text);
}

.nav-btn-primary {
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border: none;
    color: #1A150A;
    font-weight: 600;
}

.nav-btn-primary:hover {
    box-shadow: 0 4px 20px rgba(var(--primary-rgb), 0.3);
}

/* ── Preview ─────────────────────────────────────────────────── */
.preview-area {
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    padding: 1.25rem;
    min-height: 300px;
    max-height: 500px;
    overflow-y: auto;
    font-size: 0.85rem;
    line-height: 1.7;
    margin-bottom: 1rem;
}

.preview-area h1 {
    font-size: 1.25rem;
    color: var(--primary);
    margin-bottom: 0.75rem;
}

.preview-area h2 {
    font-size: 1rem;
    color: var(--secondary);
    margin: 1rem 0 0.375rem;
}

.preview-area h3 {
    font-size: 0.9rem;
    color: var(--text);
    margin: 0.75rem 0 0.25rem;
}

.preview-area p {
    margin-bottom: 0.5rem;
    color: var(--text-muted);
}

.preview-area ul {
    padding-left: 1.25rem;
    margin-bottom: 0.5rem;
    color: var(--text-muted);
}

.preview-area li {
    margin-bottom: 0.25rem;
}

/* ── Export Row ───────────────────────────────────────────────── */
.export-row {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.export-btn {
    padding: 0.5rem 1rem;
    background: var(--bg-elevated);
    border: 1px solid var(--border);
    border-radius: var(--radius-sm);
    color: var(--text-muted);
    font-family: var(--font);
    font-size: 0.8rem;
    cursor: pointer;
    transition: border-color var(--transition), color var(--transition);
}

.export-btn:hover {
    border-color: var(--border-hover);
    color: var(--text);
}

.export-btn-primary {
    background: rgba(var(--primary-rgb), 0.15);
    border-color: rgba(var(--primary-rgb), 0.3);
    color: var(--primary);
}

.export-btn-primary:hover {
    background: rgba(var(--primary-rgb), 0.25);
}

/* ── Toast ────────────────────────────────────────────────────── */
.toast {
    position: fixed;
    bottom: 2rem;
    left: 50%;
    transform: translateX(-50%) translateY(20px);
    background: var(--primary);
    color: #1A150A;
    padding: 0.6rem 1.25rem;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease, transform 0.3s ease;
    z-index: 200;
}

.toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
}

/* ── Footer ──────────────────────────────────────────────────── */
.app-footer {
    text-align: center;
    padding: 2rem 0 0.5rem;
    color: var(--text-dim);
    font-size: 0.7rem;
}

.hidden {
    display: none !important;
}

@media (max-width: 540px) {
    .app-header h1 {
        font-size: 1.25rem;
    }

    .checkbox-grid {
        grid-template-columns: 1fr;
    }

    .export-row {
        flex-direction: column;
    }

    .nav-btn {
        padding: 0.5rem 1rem;
        font-size: 0.8rem;
    }
}