/* Reset e Variáveis */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-purple: #6B46C1;
    --primary-purple-dark: #5B21B6;
    --primary-purple-light: #9333EA;
    --accent-yellow: #F59E0B;
    --accent-yellow-light: #FEF3C7;
    --text-dark: #1F2937;
    --text-light: #6B7280;
    --bg-light: #F9FAFB;
    --white: #FFFFFF;
    --success: #10B981;
    --error: #EF4444;
    --border: #E5E7EB;
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.08);
    --shadow-lg: 0 8px 24px rgba(0, 0, 0, 0.12);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: var(--bg-light);
    color: var(--text-dark);
    line-height: 1.6;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Melhorar legibilidade */
* {
    -webkit-tap-highlight-color: transparent;
}

/* Foco visível para acessibilidade */
*:focus-visible {
    outline: 3px solid var(--primary-purple);
    outline-offset: 2px;
    border-radius: 4px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    width: 100%;
}

@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
}

/* Header */
.header {
    background: linear-gradient(135deg, var(--primary-purple) 0%, var(--primary-purple-light) 100%);
    color: var(--white);
    padding: 25px 0;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 40px;
}

.logo {
    display: flex;
    align-items: center;
    flex-shrink: 0;
}

.logo a {
    display: flex;
    align-items: center;
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.logo a:hover {
    opacity: 0.9;
}

.logo-img {
    height: 70px;
    width: auto;
    max-width: 250px;
    object-fit: contain;
}

.main-nav {
    display: flex;
    align-items: center;
    flex: 1;
    justify-content: flex-end;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 40px;
    margin: 0;
    padding: 0;
    align-items: center;
}

.nav-menu li {
    margin: 0;
    padding: 0;
}

.nav-link {
    color: var(--white);
    text-decoration: none;
    font-size: 17px;
    font-weight: 600;
    padding: 12px 0;
    transition: all 0.3s ease;
    display: inline-block;
    position: relative;
    background: none;
    border: none;
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 3px;
    background: var(--accent-yellow);
    transition: width 0.3s ease;
}

.nav-link:hover::after {
    width: 100%;
}

.nav-link.active::after {
    width: 100%;
}

.nav-link:hover {
    color: var(--white);
    transform: translateY(-2px);
}

.nav-link.active {
    color: var(--white);
}

.nav-toggle {
    display: none;
    flex-direction: column;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    gap: 6px;
    z-index: 1001;
    position: relative;
}

.nav-toggle span {
    width: 28px;
    height: 3px;
    background: var(--white);
    border-radius: 3px;
    transition: all 0.3s ease;
    display: block;
}

/* Responsive Header */
@media (max-width: 768px) {
    .header {
        padding: 15px 0;
    }
    
    .header-content {
        gap: 20px;
    }
    
    .logo-img {
        height: 50px;
        max-width: 180px;
    }
    
    .main-nav {
        position: relative;
    }
    
    .nav-toggle {
        display: flex;
    }
    
    .nav-menu {
        display: none;
        position: fixed;
        top: 0;
        right: -100%;
        width: 280px;
        height: 100vh;
        background: linear-gradient(135deg, var(--primary-purple) 0%, var(--primary-purple-light) 100%);
        flex-direction: column;
        gap: 0;
        padding: 80px 30px 30px;
        box-shadow: -4px 0 20px rgba(0, 0, 0, 0.3);
        transition: right 0.3s ease;
        align-items: flex-start;
        overflow-y: auto;
    }
    
    .nav-menu.active {
        display: flex;
        right: 0;
    }
    
    .nav-link {
        width: 100%;
        text-align: left;
        padding: 15px 0;
        font-size: 18px;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .nav-link::after {
        height: 2px;
        bottom: -1px;
    }
    
    .nav-link:hover {
        transform: translateX(5px);
    }
    
    .nav-link.active::after {
        width: 50px;
    }
    
    .nav-toggle.active span:nth-child(1) {
        transform: rotate(45deg) translate(9px, 9px);
    }
    
    .nav-toggle.active span:nth-child(2) {
        opacity: 0;
        transform: translateX(-20px);
    }
    
    .nav-toggle.active span:nth-child(3) {
        transform: rotate(-45deg) translate(8px, -8px);
    }
    
}

/* Main Content */
.main-content {
    padding: 40px 0;
    min-height: calc(100vh - 200px);
}

/* Progress Indicator */
.progress-indicator {
    margin-bottom: 40px;
    padding: 20px 0;
}

.progress-steps {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 600px;
    margin: 0 auto;
    position: relative;
}

.progress-steps::before {
    content: '';
    position: absolute;
    top: 25px;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--border);
    z-index: 0;
}

.progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    position: relative;
    z-index: 1;
    flex: 1;
}

.progress-step-number {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background: var(--white);
    border: 3px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 18px;
    color: var(--text-light);
    transition: all 0.3s ease;
}

.progress-step-label {
    font-size: 13px;
    color: var(--text-light);
    font-weight: 600;
    text-align: center;
    max-width: 100px;
}

.progress-step.active .progress-step-number {
    background: var(--primary-purple);
    border-color: var(--primary-purple);
    color: var(--white);
    transform: scale(1.1);
    box-shadow: 0 4px 12px rgba(107, 70, 193, 0.3);
}

.progress-step.completed .progress-step-number {
    background: var(--success);
    border-color: var(--success);
    color: var(--white);
}

.progress-step.completed .progress-step-number::after {
    content: '✓';
    font-size: 20px;
}

.progress-step.active .progress-step-label,
.progress-step.completed .progress-step-label {
    color: var(--primary-purple);
    font-weight: 700;
}

@media (max-width: 768px) {
    .main-content {
        padding: 20px 0;
        min-height: calc(100vh - 150px);
    }
    
    .progress-indicator {
        margin-bottom: 30px;
        padding: 15px 0;
    }
    
    .progress-step-number {
        width: 40px;
        height: 40px;
        font-size: 16px;
    }
    
    .progress-step-label {
        font-size: 11px;
        max-width: 70px;
    }
    
    .progress-steps::before {
        top: 20px;
    }
}

.step {
    display: none;
}

.step.active {
    display: block;
}

/* Card */
.card {
    background: var(--white);
    border-radius: 16px;
    padding: 45px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    margin-bottom: 30px;
    border: 1px solid rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease;
}

.card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.12);
}

.step-header {
    margin-bottom: 30px;
}

.step-badge {
    display: inline-block;
    background: var(--accent-yellow-light);
    color: var(--primary-purple);
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 13px;
    font-weight: 700;
    margin-bottom: 15px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.card h2 {
    color: var(--primary-purple);
    font-size: 28px;
    margin-bottom: 10px;
    font-weight: 700;
    line-height: 1.3;
}

.subtitle {
    color: var(--text-light);
    margin-bottom: 0;
    font-size: 16px;
    line-height: 1.6;
}

.subtitle strong {
    color: var(--text-dark);
    font-weight: 600;
}

@media (max-width: 768px) {
    .step-header {
        margin-bottom: 25px;
    }
    
    .step-badge {
        font-size: 11px;
        padding: 5px 12px;
        margin-bottom: 12px;
    }
    
    .card h2 {
        font-size: 22px;
        margin-bottom: 8px;
    }
    
    .subtitle {
        font-size: 15px;
        line-height: 1.5;
    }
}

/* Tipo de Sorteio Options */
.tipo-sorteio-options {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-top: 30px;
}

.option-card {
    background: var(--white);
    border: 3px solid var(--border);
    border-radius: 16px;
    padding: 35px 25px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.option-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--primary-purple);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.option-card:hover {
    border-color: var(--primary-purple);
    transform: translateY(-8px);
    box-shadow: 0 12px 24px rgba(107, 70, 193, 0.15);
}

.option-card:hover::before {
    transform: scaleX(1);
}

.option-card.selected {
    border-color: var(--primary-purple);
    background: var(--accent-yellow-light);
    box-shadow: 0 8px 20px rgba(107, 70, 193, 0.2);
    transform: translateY(-5px);
}

.option-card.selected::before {
    transform: scaleX(1);
    background: var(--accent-yellow);
}

.option-card:focus-within {
    outline: 3px solid var(--primary-purple);
    outline-offset: 2px;
}

.option-icon {
    font-size: 48px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.option-icon i {
    font-size: inherit;
    color: var(--primary-purple);
}

.option-card h3 {
    color: var(--primary-purple);
    font-size: 20px;
    margin-bottom: 10px;
}

.option-card p {
    color: var(--text-light);
    font-size: 14px;
}

@media (max-width: 768px) {
    .option-card {
        padding: 20px;
    }
    
    .option-icon {
        font-size: 36px;
        margin-bottom: 10px;
    }
    
    .option-card h3 {
        font-size: 18px;
    }
    
    .option-card p {
        font-size: 13px;
    }
}

/* Form */
.form-group {
    margin-bottom: 25px;
}

.form-group label {
    display: block;
    margin-bottom: 10px;
    color: var(--text-dark);
    font-weight: 600;
    font-size: 15px;
    line-height: 1.4;
}

.form-group label .required {
    color: var(--error);
    margin-left: 3px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 14px 18px;
    border: 2px solid var(--border);
    border-radius: 10px;
    font-size: 16px;
    font-family: inherit;
    transition: all 0.3s ease;
    background: var(--white);
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-purple);
    box-shadow: 0 0 0 4px rgba(107, 70, 193, 0.1);
    transform: translateY(-1px);
}

.form-group input:valid:not(:placeholder-shown),
.form-group textarea:valid:not(:placeholder-shown) {
    border-color: var(--success);
}

.form-group input:invalid:not(:placeholder-shown):not(:focus),
.form-group textarea:invalid:not(:placeholder-shown):not(:focus) {
    border-color: var(--error);
}

@media (max-width: 768px) {
    .form-group input,
    .form-group textarea,
    .form-group select {
        padding: 10px 14px;
        font-size: 16px; /* Mantém 16px para evitar zoom no iOS */
    }
    
    .form-group label {
        font-size: 14px;
    }
    
    .form-group small {
        font-size: 12px;
        display: block;
        margin-top: 4px;
    }
}

/* Removido - já está acima com melhorias */

.form-group input[style*="border-color: rgb(239, 68, 68)"],
.form-group input[style*="border-color: #EF4444"] {
    border-color: #EF4444 !important;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.aviso-duplicidade {
    display: block;
    margin-top: 6px;
    font-weight: 500;
    font-size: 13px;
}

.form-help {
    display: block;
    margin-top: 6px;
    color: var(--text-light);
    font-size: 13px;
    line-height: 1.4;
}

.btn-outline:disabled {
    opacity: 0.5;
    cursor: not-allowed !important;
    pointer-events: none;
}

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

/* Participantes */
.participante-item {
    background: var(--white);
    border: 2px solid var(--border);
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
    position: relative;
    transition: all 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.participante-item:hover {
    border-color: var(--primary-purple);
    box-shadow: 0 4px 12px rgba(107, 70, 193, 0.1);
    transform: translateY(-2px);
}

.participante-item:focus-within {
    border-color: var(--primary-purple);
    box-shadow: 0 0 0 4px rgba(107, 70, 193, 0.1);
}

.participante-item-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.participante-item-header h4 {
    color: var(--primary-purple);
    font-size: 16px;
}

@media (max-width: 768px) {
    .participante-item {
        padding: 15px;
    }
    
    .participante-item-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .participante-item-header h4 {
        font-size: 15px;
    }
    
    .btn-remove {
        align-self: flex-end;
        padding: 8px 16px;
        font-size: 13px;
    }
}

.btn-remove {
    background: var(--error);
    color: var(--white);
    border: none;
    border-radius: 8px;
    padding: 8px 16px;
    cursor: pointer;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

.btn-remove::before {
    content: '×';
    font-size: 18px;
    font-weight: bold;
}

.btn-remove:hover {
    background: #DC2626;
    transform: scale(1.05);
    box-shadow: 0 4px 8px rgba(239, 68, 68, 0.3);
}

.btn-remove:focus {
    outline: 3px solid var(--error);
    outline-offset: 2px;
}

.participante-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.participante-fields.full-width {
    grid-template-columns: 1fr;
}

/* Buttons */
.btn {
    padding: 14px 28px;
    border: none;
    border-radius: 10px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-block;
    text-decoration: none;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::before {
    width: 300px;
    height: 300px;
}

.btn:focus {
    outline: 3px solid var(--primary-purple);
    outline-offset: 2px;
}

@media (max-width: 768px) {
    .btn {
        padding: 14px 20px;
        font-size: 16px;
        width: 100%;
        display: block;
    }
    
    .btn-outline {
        margin-top: 15px;
    }
}

.btn-primary {
    background: var(--primary-purple);
    color: var(--white);
}

.btn-primary:hover {
    background: var(--primary-purple-dark);
    transform: translateY(-3px);
    box-shadow: 0 6px 20px rgba(107, 70, 193, 0.4);
}

.btn-primary:active {
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--text-light);
    color: var(--white);
}

.btn-secondary:hover {
    background: #4B5563;
}

.btn-outline {
    background: transparent;
    color: var(--primary-purple);
    border: 2px solid var(--primary-purple);
    width: 100%;
    margin-top: 20px;
}

.btn-outline:hover {
    background: var(--primary-purple);
    color: var(--white);
}

.btn-success {
    background: var(--success);
    color: var(--white);
}

.btn-success:hover {
    background: #059669;
}

/* Links WhatsApp - garantir funcionamento no mobile */
.btn-whatsapp-link,
a.btn-whatsapp-link {
    pointer-events: auto !important;
    cursor: pointer !important;
    -webkit-tap-highlight-color: rgba(16, 185, 129, 0.3) !important;
    touch-action: manipulation !important;
    user-select: none !important;
    -webkit-user-select: none !important;
    position: relative !important;
    z-index: 1000 !important; /* Z-index alto para ficar acima de overlays */
    min-height: 48px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    gap: 8px;
    transition: all 0.2s ease !important;
    -webkit-touch-callout: none !important; /* Desabilita menu de contexto no iOS */
}

.btn-whatsapp-link:active,
a.btn-whatsapp-link:active {
    background: #059669 !important;
    transform: scale(0.98) !important;
}

.btn-whatsapp-link:hover,
a.btn-whatsapp-link:hover {
    background: #059669 !important;
    text-decoration: none !important;
}

/* Garantir que links não sejam bloqueados por overlays */
.resultado-box .btn-whatsapp-link,
.resultado-box a.btn-whatsapp-link {
    z-index: 1001 !important;
    position: relative !important;
}

.form-actions {
    display: flex;
    gap: 15px;
    justify-content: flex-end;
    margin-top: 30px;
}

@media (max-width: 768px) {
    .form-actions {
        flex-direction: column-reverse;
        gap: 10px;
        margin-top: 20px;
    }
    
    .form-actions .btn {
        width: 100%;
        margin: 0;
    }
}

/* Loading */
.loading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 9999;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    color: var(--white);
}

.loading-overlay.active {
    display: flex;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top-color: var(--accent-yellow);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@media (max-width: 768px) {
    .loading-overlay p {
        font-size: 16px;
        padding: 0 20px;
        text-align: center;
    }
    
    .loading-spinner {
        width: 40px;
        height: 40px;
    }
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

/* Animação de Sorteio */
.animacao-sorteio-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(107, 70, 193, 0.95) 0%, rgba(147, 51, 234, 0.95) 100%);
    z-index: 10000;
    justify-content: center;
    align-items: center;
    flex-direction: column;
    color: var(--white);
    animation: fadeIn 0.3s ease;
}

.animacao-sorteio-overlay.active {
    display: flex;
}

.animacao-sorteio-content {
    text-align: center;
}

.animacao-sorteio-content h2 {
    font-size: 32px;
    margin-bottom: 40px;
    color: var(--white);
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.animacao-sorteio-content h2 i {
    font-size: inherit;
}

.animacao-texto {
    margin-top: 30px;
    font-size: 18px;
    color: var(--white);
    opacity: 0.9;
}

.dados-container {
    display: flex;
    gap: 30px;
    justify-content: center;
    align-items: center;
    perspective: 1000px;
    flex-wrap: wrap;
}

.dado {
    width: 100px;
    height: 100px;
    position: relative;
    transform-style: preserve-3d;
    animation: rollDice 2s infinite;
}

@media (max-width: 768px) {
    .dados-container {
        gap: 15px;
    }
    
    .dado {
        width: 70px;
        height: 70px;
    }
    
    .dado .face {
        width: 70px;
        height: 70px;
        font-size: 35px;
    }
    
    .dado .face.front {
        transform: rotateY(0deg) translateZ(35px);
    }
    
    .dado .face.back {
        transform: rotateY(180deg) translateZ(35px);
    }
    
    .dado .face.right {
        transform: rotateY(90deg) translateZ(35px);
    }
    
    .dado .face.left {
        transform: rotateY(-90deg) translateZ(35px);
    }
    
    .dado .face.top {
        transform: rotateX(90deg) translateZ(35px);
    }
    
    .dado .face.bottom {
        transform: rotateX(-90deg) translateZ(35px);
    }
    
    .animacao-sorteio-content h2 {
        font-size: 24px;
        margin-bottom: 30px;
    }
    
    .animacao-texto {
        font-size: 14px;
        margin-top: 20px;
        padding: 0 20px;
    }
}

.dado:nth-child(1) {
    animation-delay: 0s;
}

.dado:nth-child(2) {
    animation-delay: 0.2s;
}

.dado:nth-child(3) {
    animation-delay: 0.4s;
}

.dado .face {
    position: absolute;
    width: 100px;
    height: 100px;
    background: var(--white);
    border: 2px solid var(--primary-purple);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 50px;
    font-weight: bold;
    color: var(--primary-purple);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.dado .face i {
    font-size: inherit;
    color: inherit;
}

.dado .face.front {
    transform: rotateY(0deg) translateZ(50px);
}

.dado .face.back {
    transform: rotateY(180deg) translateZ(50px);
}

.dado .face.right {
    transform: rotateY(90deg) translateZ(50px);
}

.dado .face.left {
    transform: rotateY(-90deg) translateZ(50px);
}

.dado .face.top {
    transform: rotateX(90deg) translateZ(50px);
}

.dado .face.bottom {
    transform: rotateX(-90deg) translateZ(50px);
}

@keyframes rollDice {
    0% {
        transform: rotateX(0deg) rotateY(0deg) rotateZ(0deg);
    }
    25% {
        transform: rotateX(90deg) rotateY(180deg) rotateZ(90deg);
    }
    50% {
        transform: rotateX(180deg) rotateY(360deg) rotateZ(180deg);
    }
    75% {
        transform: rotateX(270deg) rotateY(540deg) rotateZ(270deg);
    }
    100% {
        transform: rotateX(360deg) rotateY(720deg) rotateZ(360deg);
    }
}

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

/* Toast */
.toast {
    position: fixed;
    bottom: 20px;
    right: 20px;
    padding: 16px 24px;
    background: var(--text-dark);
    color: var(--white);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.2);
    display: none;
    z-index: 10000;
    animation: slideIn 0.3s ease;
    max-width: calc(100% - 40px);
    word-wrap: break-word;
}

@media (max-width: 768px) {
    .toast {
        bottom: 10px;
        right: 10px;
        left: 10px;
        padding: 14px 18px;
        font-size: 14px;
        max-width: none;
    }
}

.toast.show {
    display: block;
}

.toast.success {
    background: var(--success);
}

.toast.error {
    background: var(--error);
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Cores */
.cor-item {
    background: var(--bg-light);
    border: 2px solid var(--border);
    border-radius: 8px;
    padding: 15px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.cor-preview {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    border: 2px solid var(--border);
    flex-shrink: 0;
}

@media (max-width: 768px) {
    .cor-item {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        padding: 12px;
    }
    
    .cor-preview {
        width: 100%;
        height: 80px;
        align-self: center;
        max-width: 200px;
    }
    
    .cor-input-wrapper {
        flex-direction: column;
        gap: 10px;
    }
    
    .cor-input-wrapper select {
        width: 100%;
    }
}

.cor-input-wrapper {
    flex: 1;
    display: flex;
    gap: 10px;
    align-items: center;
}

.cor-input-wrapper select {
    flex: 1;
    padding: 10px;
    border: 2px solid var(--border);
    border-radius: 6px;
    font-size: 16px;
    font-family: inherit;
    background: var(--white);
    cursor: pointer;
    transition: border-color 0.3s ease;
}

.cor-input-wrapper select:focus {
    outline: none;
    border-color: var(--primary-purple);
}

.info-box {
    background: var(--accent-yellow-light);
    border-left: 4px solid var(--accent-yellow);
    padding: 18px 20px;
    border-radius: 10px;
    margin: 20px 0;
    box-shadow: 0 2px 8px rgba(245, 158, 11, 0.1);
}

.info-box p {
    margin: 6px 0;
    color: var(--text-dark);
    line-height: 1.6;
    font-size: 15px;
}

.info-box strong {
    color: var(--primary-purple);
    font-weight: 700;
}

/* Resultado */
.resultado-box {
    text-align: center;
    padding: 40px;
    position: relative;
    z-index: 1; /* Garantir que fique acima de overlays */
}

@media (max-width: 768px) {
    .resultado-box {
        padding: 20px;
    }
    
    .resultado-box h2 {
        font-size: 22px;
        margin-bottom: 15px;
    }
    
    .resultado-box .success-icon {
        font-size: 48px;
        margin-bottom: 15px;
    }
    
    .resultado-info {
        padding: 15px;
        margin: 15px 0;
        text-align: left;
    }
    
    .resultado-info p {
        font-size: 14px;
        margin: 8px 0;
        word-break: break-word;
    }
}

.resultado-box h2 {
    color: var(--primary-purple);
    margin-bottom: 20px;
}

.resultado-box .success-icon {
    font-size: 64px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--success);
}

.resultado-box .success-icon i {
    font-size: inherit;
}

.resultado-info {
    background: var(--accent-yellow-light);
    border-left: 4px solid var(--accent-yellow);
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
    text-align: left;
}

.resultado-info p {
    margin: 10px 0;
    color: var(--text-dark);
}

.resultado-info strong {
    color: var(--primary-purple);
}

/* Responsive - Tablet */
@media (max-width: 1024px) and (min-width: 769px) {
    .container {
        padding: 0 30px;
    }
    
    .tipo-sorteio-options {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .participante-fields {
        grid-template-columns: repeat(2, 1fr);
    }
}

/* Responsive - Mobile */
@media (max-width: 768px) {
    .card {
        padding: 25px 20px;
        border-radius: 12px;
    }
    
    .tipo-sorteio-options {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .participante-fields {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    
    .info-box {
        padding: 12px;
        font-size: 14px;
    }
    
    .info-box p {
        margin: 5px 0;
        font-size: 13px;
    }
    
    .aviso-duplicidade {
        font-size: 11px;
        margin-top: 4px;
    }
    
    #aviso-limite-participantes {
        margin-top: 12px;
        padding: 12px;
    }
    
    #aviso-limite-participantes p {
        font-size: 13px;
    }
}

/* Responsive - Mobile Pequeno */
@media (max-width: 480px) {
    .container {
        padding: 0 10px;
    }
    
    .header {
        padding: 15px 0;
    }
    
    .logo {
        font-size: 18px;
    }
    
    .logo-icon {
        font-size: 24px;
    }
    
    .header-title {
        font-size: 20px;
    }
    
    .main-content {
        padding: 15px 0;
    }
    
    .card {
        padding: 15px;
        margin-bottom: 20px;
    }
    
    .card h2 {
        font-size: 20px;
    }
    
    .subtitle {
        font-size: 13px;
    }
    
    .option-card {
        padding: 15px;
    }
    
    .option-icon {
        font-size: 32px;
    }
    
    .form-group {
        margin-bottom: 20px;
    }
    
    .participante-item {
        padding: 12px;
    }
    
    .cor-item {
        padding: 10px;
    }
    
    .cor-preview {
        height: 60px;
    }
    
    .resultado-box {
        padding: 15px;
    }
    
    .resultado-box h2 {
        font-size: 20px;
    }
    
    .resultado-info {
        padding: 12px;
        font-size: 13px;
    }
    
    .toast {
        bottom: 10px;
        right: 10px;
        left: 10px;
        padding: 12px 16px;
        font-size: 14px;
    }
}

/* Melhorias de acessibilidade mobile */
@media (max-width: 768px) {
    /* Garantir que inputs não sejam muito pequenos */
    input[type="text"],
    input[type="email"],
    input[type="tel"],
    textarea,
    select {
        min-height: 44px; /* Tamanho mínimo recomendado para touch */
    }
    
    /* Botões maiores para facilitar toque */
    button,
    .btn {
        min-height: 44px;
        touch-action: manipulation; /* Remove delay de toque no iOS */
    }
    
    /* Melhor espaçamento para toque */
    .btn-remove {
        min-height: 36px;
        padding: 8px 14px;
    }
    
    /* Links WhatsApp - garantir que funcionem no mobile */
    .btn-whatsapp-link,
    a.btn-whatsapp-link {
        pointer-events: auto !important;
        cursor: pointer !important;
        -webkit-tap-highlight-color: rgba(16, 185, 129, 0.3) !important;
        touch-action: manipulation !important;
        user-select: none !important;
        -webkit-user-select: none !important;
        position: relative !important;
        z-index: 1000 !important; /* Z-index alto para ficar acima de overlays */
        min-height: 48px !important;
        display: flex !important;
        align-items: center !important;
        justify-content: center !important;
        gap: 8px;
    }
    
    .btn-whatsapp-link:active {
        background: #059669 !important;
        transform: scale(0.98);
    }
    
    .btn-whatsapp-link:hover {
        background: #059669 !important;
    }
}

