/* ============================================================
   style.css
   Version: v1.0.0000
   Dark, bright, mobile-first theme for the feedback form + admin.
   CHANGELOG:
   v1.0.0000 — Initial build
   ============================================================ */

:root {
    --bg: #0b0e17;
    --bg-card: #151a29;
    --bg-input: #0f1420;
    --border: #262d42;
    --text: #f4f6fb;
    --text-muted: #9aa3ba;
    --accent-1: #ff5fa2;   /* hot pink */
    --accent-2: #7c5cff;   /* electric purple */
    --accent-3: #33e0c8;   /* bright teal */
    --success: #38e07a;
    --danger: #ff6767;
    --gradient: linear-gradient(135deg, var(--accent-2), var(--accent-1));
    --shadow: 0 10px 30px rgba(0, 0, 0, 0.35);
    --radius: 16px;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
    -webkit-tap-highlight-color: transparent;
}

body {
    background:
        radial-gradient(600px circle at 15% -10%, rgba(124, 92, 255, 0.25), transparent 60%),
        radial-gradient(600px circle at 100% 0%, rgba(255, 95, 162, 0.18), transparent 55%),
        var(--bg);
    min-height: 100vh;
}

.wrap {
    max-width: 560px;
    margin: 0 auto;
    padding: 28px 18px 60px;
}

.header {
    text-align: center;
    margin-bottom: 24px;
}

.header .badge {
    display: inline-block;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: var(--accent-3);
    background: rgba(51, 224, 200, 0.1);
    border: 1px solid rgba(51, 224, 200, 0.3);
    border-radius: 999px;
    padding: 5px 14px;
    margin-bottom: 14px;
}

.header h1 {
    font-size: 28px;
    line-height: 1.2;
    margin: 0 0 8px;
    background: var(--gradient);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.header p {
    color: var(--text-muted);
    margin: 0;
    font-size: 15px;
}

.card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    box-shadow: var(--shadow);
    padding: 20px;
    margin-bottom: 16px;
}

label {
    display: block;
    font-weight: 600;
    font-size: 14.5px;
    margin-bottom: 8px;
}

label .req { color: var(--accent-1); }

.field { margin-bottom: 18px; }
.field:last-child { margin-bottom: 0; }

.label-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
}

.counter {
    font-size: 12.5px;
    color: var(--text-muted);
}

input[type="text"],
input[type="email"],
textarea {
    width: 100%;
    background: var(--bg-input);
    border: 1px solid var(--border);
    color: var(--text);
    border-radius: 12px;
    padding: 13px 14px;
    font-size: 16px; /* 16px avoids iOS zoom-on-focus */
    font-family: inherit;
    transition: border-color 0.15s, box-shadow 0.15s;
}

input[type="text"]:focus,
input[type="email"]:focus,
textarea:focus {
    outline: none;
    border-color: var(--accent-2);
    box-shadow: 0 0 0 3px rgba(124, 92, 255, 0.25);
}

textarea {
    resize: vertical;
    min-height: 140px;
    line-height: 1.5;
}

::placeholder { color: #5c6480; }

.rewrite-btn {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-top: 10px;
    background: rgba(124, 92, 255, 0.12);
    border: 1px solid rgba(124, 92, 255, 0.4);
    color: #c9bfff;
    font-size: 13.5px;
    font-weight: 600;
    padding: 9px 14px;
    border-radius: 999px;
    cursor: pointer;
    transition: transform 0.1s, background 0.15s;
}

.rewrite-btn:active { transform: scale(0.97); }
.rewrite-btn:disabled { opacity: 0.6; cursor: default; }
.rewrite-btn svg { width: 15px; height: 15px; flex-shrink: 0; }

.rewrite-hint {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 6px;
    display: none;
}
.rewrite-hint.show { display: block; }

/* Share toggle */
.toggle-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 14px;
}

.toggle-row .copy h3 {
    margin: 0 0 4px;
    font-size: 15.5px;
}

.toggle-row .copy p {
    margin: 0;
    font-size: 13px;
    color: var(--text-muted);
    line-height: 1.4;
}

.switch {
    position: relative;
    width: 50px;
    height: 30px;
    flex-shrink: 0;
}

.switch input { opacity: 0; width: 0; height: 0; }

.switch .track {
    position: absolute;
    inset: 0;
    background: #333c58;
    border-radius: 999px;
    cursor: pointer;
    transition: background 0.2s;
}

.switch .track::before {
    content: "";
    position: absolute;
    height: 24px;
    width: 24px;
    left: 3px;
    top: 3px;
    background: #fff;
    border-radius: 50%;
    transition: transform 0.2s;
}

.switch input:checked + .track { background: var(--gradient); }
.switch input:checked + .track::before { transform: translateX(20px); }

.divider {
    height: 1px;
    background: var(--border);
    margin: 18px 0;
}

/* Photo section */
.photo-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-top: 12px;
}

.photo-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: var(--bg-input);
    border: 1.5px dashed var(--border);
    color: var(--text);
    border-radius: 14px;
    padding: 18px 10px;
    font-size: 13.5px;
    font-weight: 600;
    cursor: pointer;
    transition: border-color 0.15s, background 0.15s;
}

.photo-btn:active { transform: scale(0.98); }
.photo-btn:hover { border-color: var(--accent-2); }
.photo-btn svg { width: 24px; height: 24px; color: var(--accent-3); }

.photo-preview {
    display: none;
    margin-top: 14px;
    position: relative;
}
.photo-preview.show { display: block; }

.photo-preview img {
    width: 100%;
    max-height: 280px;
    object-fit: cover;
    border-radius: 14px;
    border: 1px solid var(--border);
    display: block;
}

.photo-remove {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(11, 14, 23, 0.85);
    border: 1px solid var(--border);
    color: var(--text);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    line-height: 1;
}

.submit-btn {
    width: 100%;
    background: var(--gradient);
    color: #fff;
    font-size: 17px;
    font-weight: 700;
    border: none;
    border-radius: 14px;
    padding: 16px;
    cursor: pointer;
    box-shadow: 0 8px 24px rgba(124, 92, 255, 0.35);
    transition: transform 0.1s, opacity 0.15s;
}

.submit-btn:active { transform: scale(0.98); }
.submit-btn:disabled { opacity: 0.6; cursor: default; }

.error-banner {
    display: none;
    background: rgba(255, 103, 103, 0.12);
    border: 1px solid rgba(255, 103, 103, 0.4);
    color: #ffb3b3;
    padding: 12px 14px;
    border-radius: 12px;
    font-size: 13.5px;
    margin-bottom: 16px;
}
.error-banner.show { display: block; }

/* Success state */
.success-view {
    display: none;
    text-align: center;
    padding: 50px 20px 30px;
}
.success-view.show { display: block; }

.success-icon {
    width: 76px;
    height: 76px;
    border-radius: 50%;
    background: var(--gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 10px 30px rgba(124, 92, 255, 0.4);
}
.success-icon svg { width: 38px; height: 38px; color: #fff; }

.success-view h2 {
    font-size: 24px;
    margin: 0 0 10px;
}
.success-view p {
    color: var(--text-muted);
    margin: 0;
    font-size: 15px;
    line-height: 1.5;
}

.form-view.hide { display: none; }

.footer-note {
    text-align: center;
    color: var(--text-muted);
    font-size: 12.5px;
    margin-top: 22px;
    line-height: 1.6;
}

.footer-note a { color: var(--accent-3); text-decoration: none; }

@media (min-width: 640px) {
    .wrap { padding-top: 48px; }
    .header h1 { font-size: 32px; }
    .card { padding: 28px; }
}

/* ---- Admin dashboard ---- */
.admin-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 900px;
    margin: 0 auto;
    padding: 18px 18px 0;
}
.admin-nav h1 { font-size: 20px; margin: 0; }
.admin-nav a {
    color: var(--text-muted);
    font-size: 13.5px;
    text-decoration: none;
    border: 1px solid var(--border);
    padding: 7px 14px;
    border-radius: 999px;
}

.admin-wrap { max-width: 900px; margin: 0 auto; padding: 18px; }

.filters { display: flex; gap: 8px; margin-bottom: 18px; flex-wrap: wrap; }
.filter-pill {
    font-size: 13px;
    font-weight: 600;
    padding: 8px 14px;
    border-radius: 999px;
    border: 1px solid var(--border);
    color: var(--text-muted);
    text-decoration: none;
}
.filter-pill.active { background: var(--gradient); color: #fff; border-color: transparent; }

.t-card {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 18px;
    margin-bottom: 14px;
    display: flex;
    gap: 16px;
}
.t-card img.thumb {
    width: 72px;
    height: 72px;
    border-radius: 12px;
    object-fit: cover;
    flex-shrink: 0;
    border: 1px solid var(--border);
}
.t-body { flex: 1; min-width: 0; }
.t-head { display: flex; justify-content: space-between; gap: 10px; }
.t-head strong { font-size: 15.5px; }
.t-head span.email { display: block; color: var(--text-muted); font-size: 12.5px; }
.t-text { margin: 10px 0; font-size: 14.5px; line-height: 1.5; color: #dfe3ee; }
.t-meta { font-size: 12px; color: var(--text-muted); margin-bottom: 10px; }
.t-actions { display: flex; gap: 8px; flex-wrap: wrap; }
.t-btn {
    font-size: 12.5px;
    font-weight: 600;
    padding: 7px 12px;
    border-radius: 999px;
    border: 1px solid var(--border);
    background: var(--bg-input);
    color: var(--text);
    cursor: pointer;
}
.t-btn.approve { border-color: rgba(56, 224, 122, 0.5); color: var(--success); }
.t-btn.decline { border-color: rgba(255, 103, 103, 0.5); color: var(--danger); }
.t-btn.feature.active { background: var(--gradient); color: #fff; border-color: transparent; }
.status-tag {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 3px 9px;
    border-radius: 999px;
    flex-shrink: 0;
    height: fit-content;
}
.status-tag.pending { background: rgba(154, 163, 186, 0.15); color: var(--text-muted); }
.status-tag.approved { background: rgba(56, 224, 122, 0.15); color: var(--success); }
.status-tag.declined { background: rgba(255, 103, 103, 0.15); color: var(--danger); }

.login-wrap {
    max-width: 380px;
    margin: 0 auto;
    padding: 80px 20px;
    text-align: center;
}
.oauth-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    padding: 14px;
    border-radius: 12px;
    border: 1px solid var(--border);
    background: var(--bg-card);
    color: var(--text);
    font-weight: 600;
    font-size: 15px;
    text-decoration: none;
    margin-bottom: 12px;
}
