/* ===========================================
   SONHOS — Design System Premium
   =========================================== */

/* ---------- Google Fonts ---------- */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800;900&family=Outfit:wght@300;400;500;600;700;800&display=swap');

/* ---------- CSS Variables ---------- */
:root {
    /* Cores principais */
    --bg-primary: #0A0A10;
    --bg-secondary: #12121A;
    --bg-card: rgba(255, 255, 255, 0.04);
    --bg-card-hover: rgba(255, 255, 255, 0.07);
    --bg-glass: rgba(255, 255, 255, 0.06);

    /* Accent */
    --accent: #7C3AED;
    --accent-light: #A78BFA;
    --accent-dark: #5B21B6;
    --accent-glow: rgba(124, 58, 237, 0.3);

    /* Gradientes */
    --gradient-primary: linear-gradient(135deg, #7C3AED 0%, #3B82F6 100%);
    --gradient-hero: linear-gradient(135deg, #7C3AED 0%, #EC4899 50%, #3B82F6 100%);
    --gradient-card: linear-gradient(135deg, rgba(124, 58, 237, 0.15) 0%, rgba(59, 130, 246, 0.08) 100%);
    --gradient-subtle: linear-gradient(135deg, rgba(124, 58, 237, 0.08) 0%, rgba(59, 130, 246, 0.04) 100%);

    /* Texto */
    --text-primary: #F8FAFC;
    --text-secondary: #94A3B8;
    --text-muted: #64748B;
    --text-accent: #A78BFA;

    /* Bordas */
    --border: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(255, 255, 255, 0.15);
    --border-accent: rgba(124, 58, 237, 0.4);

    /* Sombras */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.3);
    --shadow-md: 0 4px 24px rgba(0, 0, 0, 0.4);
    --shadow-lg: 0 8px 40px rgba(0, 0, 0, 0.5);
    --shadow-glow: 0 0 30px rgba(124, 58, 237, 0.2);

    /* Espaçamentos */
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 20px;
    --radius-xl: 28px;
    --radius-full: 9999px;

    /* Status */
    --status-novo: #3B82F6;
    --status-andamento: #F59E0B;
    --status-concluido: #10B981;
    --status-cancelado: #EF4444;

    /* Tipografia */
    --font-primary: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    --font-display: 'Outfit', 'Inter', sans-serif;
}

/* ---------- Reset & Base ---------- */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    display: block;
}

/* ---------- Typography ---------- */
.font-display {
    font-family: var(--font-display);
}

.text-gradient {
    background: var(--gradient-hero);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.text-gradient-simple {
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

/* ---------- Container ---------- */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-sm {
    max-width: 680px;
    margin: 0 auto;
    padding: 0 24px;
}

.container-lg {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 24px;
}

/* ---------- Cards ---------- */
.card-glass {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    transition: all 0.3s ease;
}

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

.card-solid {
    background: var(--bg-secondary);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    transition: all 0.3s ease;
}

.card-accent {
    background: var(--gradient-card);
    border: 1px solid var(--border-accent);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-glow);
}

/* ---------- Buttons ---------- */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 28px;
    border-radius: var(--radius-full);
    font-family: var(--font-primary);
    font-weight: 600;
    font-size: 15px;
    border: none;
    cursor: pointer;
    transition: all 0.25s ease;
    white-space: nowrap;
    text-decoration: none;
}

.btn:active {
    transform: scale(0.97);
}

.btn-primary {
    background: var(--gradient-primary);
    color: white;
    box-shadow: 0 4px 20px rgba(124, 58, 237, 0.3);
}

.btn-primary:hover {
    box-shadow: 0 6px 30px rgba(124, 58, 237, 0.45);
    transform: translateY(-2px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.08);
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.12);
    border-color: var(--border-hover);
}

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

.btn-outline:hover {
    background: rgba(124, 58, 237, 0.1);
}

.btn-danger {
    background: rgba(239, 68, 68, 0.15);
    color: #FCA5A5;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
    background: rgba(239, 68, 68, 0.25);
}

.btn-sm {
    padding: 8px 18px;
    font-size: 13px;
}

.btn-lg {
    padding: 18px 36px;
    font-size: 17px;
}

.btn-block {
    width: 100%;
}

.btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none !important;
}

/* ---------- Form Inputs ---------- */
.form-group {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.form-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-secondary);
    padding-left: 4px;
}

.form-input {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 14px 18px;
    color: var(--text-primary);
    font-family: var(--font-primary);
    font-size: 15px;
    transition: all 0.2s ease;
    width: 100%;
}

.form-input::placeholder {
    color: var(--text-muted);
}

.form-input:focus {
    outline: none;
    border-color: var(--accent);
    box-shadow: 0 0 0 4px var(--accent-glow);
    background: rgba(255, 255, 255, 0.07);
}

.form-input:hover {
    border-color: var(--border-hover);
}

textarea.form-input {
    resize: vertical;
    min-height: 100px;
}

select.form-input {
    appearance: none;
    background-image: url("data:image/svg+xml;charset=utf-8,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 20 20'%3E%3Cpath stroke='%2394A3B8' stroke-linecap='round' stroke-linejoin='round' stroke-width='1.5' d='m6 8 4 4 4-4'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    background-size: 16px;
    padding-right: 40px;
}

select.form-input option {
    background: var(--bg-secondary);
    color: var(--text-primary);
}

/* ---------- Badges ---------- */
.badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 12px;
    border-radius: var(--radius-full);
    font-size: 12px;
    font-weight: 600;
    letter-spacing: 0.3px;
}

.badge-novo {
    background: rgba(59, 130, 246, 0.15);
    color: #93C5FD;
    border: 1px solid rgba(59, 130, 246, 0.3);
}

.badge-andamento {
    background: rgba(245, 158, 11, 0.15);
    color: #FCD34D;
    border: 1px solid rgba(245, 158, 11, 0.3);
}

.badge-concluido {
    background: rgba(16, 185, 129, 0.15);
    color: #6EE7B7;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.badge-cancelado {
    background: rgba(239, 68, 68, 0.15);
    color: #FCA5A5;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.badge-plano {
    background: rgba(124, 58, 237, 0.15);
    color: var(--accent-light);
    border: 1px solid rgba(124, 58, 237, 0.3);
}

/* ---------- Stepper ---------- */
.stepper {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0;
    margin-bottom: 48px;
}

.stepper-step {
    display: flex;
    align-items: center;
    gap: 10px;
}

.stepper-circle {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    transition: all 0.4s ease;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-muted);
    border: 2px solid var(--border);
}

.stepper-step.active .stepper-circle {
    background: var(--gradient-primary);
    color: white;
    border-color: transparent;
    box-shadow: 0 0 20px var(--accent-glow);
}

.stepper-step.done .stepper-circle {
    background: var(--status-concluido);
    color: white;
    border-color: transparent;
}

.stepper-label {
    font-size: 13px;
    font-weight: 500;
    color: var(--text-muted);
    transition: color 0.3s ease;
}

.stepper-step.active .stepper-label {
    color: var(--text-primary);
}

.stepper-step.done .stepper-label {
    color: var(--status-concluido);
}

.stepper-line {
    width: 40px;
    height: 2px;
    background: var(--border);
    margin: 0 8px;
    transition: background 0.4s ease;
    flex-shrink: 0;
}

.stepper-line.done {
    background: var(--status-concluido);
}

/* ---------- Navbar ---------- */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 100;
    padding: 16px 0;
    transition: all 0.3s ease;
}

.navbar.scrolled {
    background: rgba(10, 10, 16, 0.85);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border);
}

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

.navbar-logo {
    font-family: var(--font-display);
    font-size: 24px;
    font-weight: 800;
}

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

.navbar-link {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: color 0.2s ease;
}

.navbar-link:hover {
    color: var(--text-primary);
}

/* ---------- Hero ---------- */
.hero {
    padding: 160px 0 100px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.hero::before {
    content: '';
    position: absolute;
    top: -50%;
    left: 50%;
    transform: translateX(-50%);
    width: 800px;
    height: 800px;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.12) 0%, transparent 70%);
    pointer-events: none;
}

.hero-title {
    font-family: var(--font-display);
    font-size: clamp(40px, 7vw, 72px);
    font-weight: 800;
    line-height: 1.1;
    margin-bottom: 24px;
    letter-spacing: -1px;
}

.hero-subtitle {
    font-size: clamp(16px, 2.5vw, 20px);
    color: var(--text-secondary);
    max-width: 560px;
    margin: 0 auto 40px;
    line-height: 1.7;
}

.hero-cta {
    display: flex;
    gap: 16px;
    justify-content: center;
    flex-wrap: wrap;
}

/* ---------- Sections ---------- */
.section {
    padding: 100px 0;
}

.section-title {
    font-family: var(--font-display);
    font-size: clamp(28px, 4vw, 42px);
    font-weight: 700;
    text-align: center;
    margin-bottom: 16px;
    letter-spacing: -0.5px;
}

.section-subtitle {
    font-size: 17px;
    color: var(--text-secondary);
    text-align: center;
    max-width: 500px;
    margin: 0 auto 60px;
}

/* ---------- How It Works ---------- */
.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
    gap: 24px;
}

.step-card {
    padding: 36px 28px;
    text-align: center;
}

.step-icon {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    background: var(--gradient-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
}

.step-icon svg {
    width: 28px;
    height: 28px;
    stroke: var(--accent-light);
}

.step-number {
    font-family: var(--font-display);
    font-size: 13px;
    font-weight: 700;
    color: var(--accent-light);
    letter-spacing: 2px;
    text-transform: uppercase;
    margin-bottom: 12px;
}

.step-title {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 8px;
}

.step-desc {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* ---------- Plans ---------- */
.plans-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 24px;
    align-items: stretch;
}

.plan-card {
    padding: 36px 28px;
    position: relative;
    display: flex;
    flex-direction: column;
}

.plan-card.featured {
    border-color: var(--border-accent);
    background: var(--gradient-card);
    box-shadow: var(--shadow-glow);
    transform: scale(1.03);
}

.plan-badge {
    position: absolute;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--gradient-primary);
    color: white;
    padding: 4px 16px;
    border-radius: var(--radius-full);
    font-size: 11px;
    font-weight: 700;
    letter-spacing: 1px;
    text-transform: uppercase;
}

.plan-name {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 700;
    margin-bottom: 4px;
}

.plan-desc {
    font-size: 14px;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.plan-price {
    font-family: var(--font-display);
    font-size: 48px;
    font-weight: 800;
    margin-bottom: 4px;
    line-height: 1;
}

.plan-price span {
    font-size: 18px;
    font-weight: 400;
    color: var(--text-secondary);
}

.plan-features {
    list-style: none;
    margin: 24px 0;
    flex: 1;
}

.plan-features li {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    font-size: 14px;
    color: var(--text-secondary);
}

.plan-features li svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    stroke: var(--status-concluido);
}

/* ---------- Testimonials ---------- */
.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
}

.testimonial-card {
    padding: 28px;
}

.testimonial-text {
    font-size: 15px;
    color: var(--text-secondary);
    line-height: 1.7;
    margin-bottom: 20px;
    font-style: italic;
}

.testimonial-author {
    display: flex;
    align-items: center;
    gap: 12px;
}

.testimonial-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--gradient-primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    color: white;
}

.testimonial-name {
    font-weight: 600;
    font-size: 14px;
}

.testimonial-plano {
    font-size: 12px;
    color: var(--text-muted);
}

/* ---------- Footer (public) ---------- */
.footer {
    border-top: 1px solid var(--border);
    padding: 48px 0 32px;
    text-align: center;
}

.footer-text {
    font-size: 13px;
    color: var(--text-muted);
}

/* ---------- Progress Bar ---------- */
.progress-bar-bg {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: var(--radius-full);
    overflow: hidden;
}

.progress-bar-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: var(--radius-full);
    transition: width 0.4s ease;
}

/* ---------- Drop Zone ---------- */
.drop-zone {
    border: 2px dashed var(--border);
    border-radius: var(--radius-lg);
    padding: 60px 40px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.drop-zone:hover,
.drop-zone.drag-over {
    border-color: var(--accent);
    background: rgba(124, 58, 237, 0.05);
}

.drop-zone-icon {
    width: 56px;
    height: 56px;
    border-radius: 16px;
    background: var(--gradient-subtle);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 16px;
}

.drop-zone-icon svg {
    width: 24px;
    height: 24px;
    stroke: var(--accent-light);
}

/* ---------- Photo Preview Card ---------- */
.photo-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 12px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.03);
    border: 1px solid var(--border);
    position: relative;
    transition: all 0.2s ease;
}

.photo-card:hover {
    border-color: var(--border-hover);
    background: rgba(255, 255, 255, 0.05);
}

.photo-thumb {
    width: 72px;
    height: 72px;
    border-radius: var(--radius-sm);
    object-fit: cover;
    flex-shrink: 0;
    background: rgba(255, 255, 255, 0.05);
}

.photo-fields {
    flex: 1;
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: 8px;
}

.photo-remove {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--status-cancelado);
    color: white;
    border: none;
    cursor: pointer;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s ease;
    box-shadow: var(--shadow-sm);
}

.photo-card:hover .photo-remove {
    opacity: 1;
}

/* ---------- Success Screen ---------- */
.success-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: rgba(16, 185, 129, 0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
    animation: pulse-success 2s infinite;
}

.success-icon svg {
    width: 36px;
    height: 36px;
    stroke: var(--status-concluido);
}

@keyframes pulse-success {
    0%, 100% { box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.3); }
    50% { box-shadow: 0 0 0 20px rgba(16, 185, 129, 0); }
}

/* ============================
   ADMIN LAYOUT
   ============================ */
.admin-layout {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 260px;
    background: var(--bg-secondary);
    border-right: 1px solid var(--border);
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 50;
}

.admin-sidebar-logo {
    font-family: var(--font-display);
    font-size: 22px;
    font-weight: 800;
    padding: 8px 12px;
    margin-bottom: 32px;
}

.admin-nav {
    list-style: none;
    flex: 1;
}

.admin-nav-item {
    margin-bottom: 4px;
}

.admin-nav-link {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 500;
    color: var(--text-secondary);
    transition: all 0.2s ease;
}

.admin-nav-link:hover {
    background: rgba(255, 255, 255, 0.05);
    color: var(--text-primary);
}

.admin-nav-link.active {
    background: rgba(124, 58, 237, 0.12);
    color: var(--accent-light);
}

.admin-nav-link svg {
    width: 20px;
    height: 20px;
    flex-shrink: 0;
}

.admin-sidebar-footer {
    border-top: 1px solid var(--border);
    padding-top: 16px;
}

.admin-content {
    flex: 1;
    margin-left: 260px;
    padding: 32px;
}

.admin-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 32px;
}

.admin-title {
    font-family: var(--font-display);
    font-size: 28px;
    font-weight: 700;
}

/* ---------- Stats Grid ---------- */
.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 20px;
    margin-bottom: 32px;
}

.stat-card {
    padding: 24px;
}

.stat-icon {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
}

.stat-icon svg {
    width: 22px;
    height: 22px;
}

.stat-value {
    font-family: var(--font-display);
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 4px;
}

.stat-label {
    font-size: 13px;
    color: var(--text-secondary);
}

/* ---------- Admin Table ---------- */
.admin-table {
    width: 100%;
    border-collapse: collapse;
}

.admin-table th {
    text-align: left;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 16px;
    border-bottom: 1px solid var(--border);
}

.admin-table td {
    padding: 16px;
    font-size: 14px;
    border-bottom: 1px solid var(--border);
    vertical-align: middle;
}

.admin-table tr:hover td {
    background: rgba(255, 255, 255, 0.02);
}

.admin-table .client-name {
    font-weight: 600;
    color: var(--text-primary);
}

.admin-table .client-phone {
    color: var(--text-secondary);
    font-size: 13px;
}

/* ---------- Client Detail ---------- */
.client-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 24px;
    flex-wrap: wrap;
}

.client-info {
    flex: 1;
}

.client-name-large {
    font-family: var(--font-display);
    font-size: 28px;
    font-weight: 700;
    margin-bottom: 8px;
}

.client-meta {
    display: flex;
    gap: 24px;
    flex-wrap: wrap;
    font-size: 14px;
    color: var(--text-secondary);
}

.client-meta-item {
    display: flex;
    align-items: center;
    gap: 6px;
}

.client-meta-item svg {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
}

.client-message {
    padding: 20px;
    margin: 24px 0;
    border-left: 3px solid var(--accent);
    font-style: italic;
    color: var(--text-secondary);
    line-height: 1.7;
}

/* ---------- Photo Gallery (admin) ---------- */
.gallery-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 16px;
}

.gallery-item {
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border);
    background: rgba(255, 255, 255, 0.03);
    cursor: pointer;
    transition: all 0.3s ease;
}

.gallery-item:hover {
    border-color: var(--border-accent);
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.gallery-item img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
}

.gallery-item-info {
    padding: 10px 12px;
}

.gallery-item-year {
    font-size: 12px;
    font-weight: 700;
    color: var(--accent-light);
}

.gallery-item-desc {
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: 2px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* ---------- Modal ---------- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 200;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    max-width: 90vw;
    max-height: 90vh;
}

.modal-content img {
    max-width: 100%;
    max-height: 85vh;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-lg);
}

.modal-close {
    position: fixed;
    top: 20px;
    right: 20px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: white;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
    z-index: 201;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* ---------- Login Page ---------- */
.login-wrapper {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    position: relative;
}

.login-wrapper::before {
    content: '';
    position: absolute;
    top: 20%;
    left: 50%;
    transform: translateX(-50%);
    width: 600px;
    height: 600px;
    background: radial-gradient(circle, rgba(124, 58, 237, 0.1) 0%, transparent 70%);
    pointer-events: none;
}

.login-card {
    width: 100%;
    max-width: 400px;
    padding: 40px;
    position: relative;
}

/* ---------- Animations ---------- */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(24px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateX(-20px);
    }
    to {
        opacity: 1;
        transform: translateX(0);
    }
}

.animate-fade-up {
    animation: fadeInUp 0.6s ease forwards;
    opacity: 0;
}

.animate-fade-in {
    animation: fadeIn 0.5s ease forwards;
    opacity: 0;
}

.animate-slide-in {
    animation: slideIn 0.5s ease forwards;
    opacity: 0;
}

.delay-1 { animation-delay: 0.1s; }
.delay-2 { animation-delay: 0.2s; }
.delay-3 { animation-delay: 0.3s; }
.delay-4 { animation-delay: 0.4s; }
.delay-5 { animation-delay: 0.5s; }

/* ---------- Utilities ---------- */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }
.gap-20 { gap: 20px; }
.gap-24 { gap: 24px; }
.text-center { text-align: center; }
.text-sm { font-size: 14px; }
.text-xs { font-size: 12px; }
.text-muted { color: var(--text-secondary); }
.mt-8 { margin-top: 8px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.mb-32 { margin-bottom: 32px; }
.p-16 { padding: 16px; }
.p-24 { padding: 24px; }
.hidden { display: none !important; }
.w-full { width: 100%; }

/* Scrollbar */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: rgba(255, 255, 255, 0.1); border-radius: 10px; }
::-webkit-scrollbar-thumb:hover { background: rgba(255, 255, 255, 0.2); }

/* ---------- Responsive ---------- */
@media (max-width: 768px) {
    .container { padding: 0 16px; }

    .hero { padding: 120px 0 60px; }

    .stepper-label { display: none; }
    .stepper-line { width: 24px; }
    .stepper-circle { width: 36px; height: 36px; font-size: 13px; }

    .plan-card.featured { transform: scale(1); }

    .photo-fields {
        grid-template-columns: 1fr;
    }

    .photo-card {
        flex-direction: column;
        align-items: stretch;
    }

    .photo-thumb {
        width: 100%;
        height: 120px;
    }

    /* Admin mobile */
    .admin-sidebar {
        transform: translateX(-100%);
        transition: transform 0.3s ease;
    }

    .admin-sidebar.open {
        transform: translateX(0);
    }

    .admin-content {
        margin-left: 0;
        padding: 20px 16px;
    }

    .admin-mobile-toggle {
        display: flex !important;
    }

    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .client-header {
        flex-direction: column;
    }

    .navbar-links { display: none; }
}

@media (min-width: 769px) {
    .admin-mobile-toggle {
        display: none !important;
    }
}

/* ============================
   ÁREA DO USUÁRIO
   ============================ */

/* Alertas */
.alert-error {
    padding: 14px 16px;
    border-radius: var(--radius-md);
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #FCA5A5;
    font-size: 14px;
}

.alert-success {
    padding: 14px 16px;
    border-radius: var(--radius-md);
    background: rgba(16, 185, 129, 0.12);
    border: 1px solid rgba(16, 185, 129, 0.3);
    color: #6EE7B7;
    font-size: 14px;
}

/* Card de pedido na listagem */
.user-order-card {
    color: var(--text-primary);
    border: 1px solid var(--border);
    transition: border-color 0.2s, transform 0.2s;
}

.user-order-card:hover {
    border-color: var(--border-accent);
    transform: translateY(-2px);
}

/* Barra de progresso do pedido */
.order-progress {
    padding: 16px 0 8px;
}

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

.btn-outline:hover {
    border-color: var(--border-accent);
    color: var(--text-primary);
}

/* ============================
   Entregas - Admin & Usuário
   ============================ */

/* Seção de entrega no admin */
.entrega-section {
    margin-bottom: 24px;
}

.entrega-section h4 {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Lista de arquivos enviados (admin) */
.entrega-lista {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 16px;
}

.entrega-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 14px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 13px;
    color: var(--text-secondary);
    transition: border-color 0.2s;
}

.entrega-item:hover {
    border-color: var(--border-accent);
}

.entrega-item .nome-arquivo {
    flex: 1;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    margin-right: 12px;
}

.entrega-item .tamanho-arquivo {
    font-size: 12px;
    color: var(--text-muted);
    margin-right: 12px;
    white-space: nowrap;
}

.entrega-item .btn-excluir {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.25);
    color: #FCA5A5;
    padding: 4px 10px;
    border-radius: var(--radius-sm);
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.entrega-item .btn-excluir:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
}

/* Upload drop area */
.upload-drop-area {
    border: 2px dashed var(--border);
    border-radius: var(--radius-md);
    padding: 24px;
    text-align: center;
    color: var(--text-muted);
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
}

.upload-drop-area:hover,
.upload-drop-area.drag-over {
    border-color: var(--accent);
    background: rgba(168, 85, 247, 0.05);
    color: var(--text-secondary);
}

.upload-drop-area input[type="file"] {
    display: none;
}

/* Progress bar de upload */
.upload-progress {
    margin-top: 12px;
    display: none;
}

.upload-progress.active {
    display: block;
}

.upload-progress .progress-bar {
    height: 6px;
    background: rgba(255, 255, 255, 0.08);
    border-radius: 3px;
    overflow: hidden;
}

.upload-progress .progress-fill {
    height: 100%;
    background: var(--accent);
    border-radius: 3px;
    width: 0%;
    transition: width 0.3s;
}

.upload-progress .progress-text {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 6px;
    text-align: right;
}

/* Downloads do usuário */
.entrega-download-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    margin-bottom: 10px;
    transition: border-color 0.2s;
}

.entrega-download-item:hover {
    border-color: var(--border-accent);
}

.entrega-download-item .icone {
    font-size: 28px;
    flex-shrink: 0;
}

.entrega-download-item .info {
    flex: 1;
    min-width: 0;
}

.entrega-download-item .info .nome {
    font-size: 14px;
    font-weight: 500;
    color: var(--text-primary);
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.entrega-download-item .info .meta {
    font-size: 12px;
    color: var(--text-muted);
    margin-top: 2px;
}

.entrega-download-item .btn-download {
    background: var(--accent);
    color: #fff;
    border: none;
    padding: 8px 16px;
    border-radius: var(--radius-sm);
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    text-decoration: none;
    transition: opacity 0.2s;
    white-space: nowrap;
}

.entrega-download-item .btn-download:hover {
    opacity: 0.85;
}

/* Grid de fotos melhoradas (usuário) */
.entrega-fotos-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 12px;
}

.entrega-foto-card {
    position: relative;
    border-radius: var(--radius-md);
    overflow: hidden;
    border: 1px solid var(--border);
    transition: border-color 0.2s, transform 0.2s;
}

.entrega-foto-card:hover {
    border-color: var(--border-accent);
    transform: translateY(-2px);
}

.entrega-foto-card img {
    width: 100%;
    aspect-ratio: 1;
    object-fit: cover;
    display: block;
}

.entrega-foto-card .overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s;
}

.entrega-foto-card:hover .overlay {
    opacity: 1;
}

.entrega-foto-card .overlay a {
    color: #fff;
    font-size: 13px;
    font-weight: 500;
    text-decoration: none;
    padding: 6px 14px;
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: var(--radius-sm);
    transition: background 0.2s;
}

.entrega-foto-card .overlay a:hover {
    background: rgba(255, 255, 255, 0.15);
}

/* ============================
   Edição de Fotos — Usuário
   ============================ */

/* Alerta informativo (bloqueio) */
.alert-info {
    padding: 14px 16px;
    border-radius: var(--radius-md);
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.25);
    color: #93C5FD;
    font-size: 14px;
}

/* Botão excluir foto no card */
.btn-excluir-foto {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(0, 0, 0, 0.65);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #fff;
    font-size: 12px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.2s, background 0.2s;
    z-index: 2;
}

.foto-usuario-card:hover .btn-excluir-foto {
    opacity: 1;
}

.btn-excluir-foto:hover {
    background: rgba(239, 68, 68, 0.8);
}

/* Botão de bloqueio no admin */
.btn-bloqueado {
    background: rgba(239, 68, 68, 0.12);
    border: 1px solid rgba(239, 68, 68, 0.3);
    color: #FCA5A5;
}

.btn-bloqueado:hover {
    background: rgba(239, 68, 68, 0.2);
    border-color: rgba(239, 68, 68, 0.5);
}

