* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    padding: 20px;
    color: #333;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    background: white;
    border-radius: 20px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    overflow: hidden;
}

header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 40px;
    text-align: center;
}

header h1 {
    font-size: 2.5em;
    margin-bottom: 30px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.prize-info {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 30px;
    flex-wrap: wrap;
}

.phone-image {
    width: 200px;
    height: 200px;
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

.prize-details {
    text-align: left;
}

.prize-details h2 {
    font-size: 1.8em;
    margin-bottom: 10px;
}

.prize-name {
    font-size: 1.5em;
    font-weight: bold;
    margin-bottom: 5px;
}

.prize-specs {
    font-size: 1.1em;
    opacity: 0.9;
}

.stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    padding: 30px;
    background: #f8f9fa;
}

.stat-card {
    background: white;
    padding: 25px;
    border-radius: 15px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
}

.stat-card h3 {
    color: #666;
    font-size: 0.9em;
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.stat-value {
    font-size: 2.5em;
    font-weight: bold;
    color: #667eea;
}

.stat-card.sold .stat-value {
    color: #e74c3c;
}

.stat-card.available .stat-value {
    color: #27ae60;
}

.progress-card {
    grid-column: 1 / -1;
}

.progress-bar {
    width: 100%;
    height: 30px;
    background: #e0e0e0;
    border-radius: 15px;
    overflow: hidden;
    margin: 15px 0;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transition: width 0.5s ease;
    border-radius: 15px;
}

.progress-text {
    font-size: 1.2em;
    font-weight: bold;
    color: #333;
}

.packages {
    padding: 40px;
    background: white;
}

.packages h2 {
    text-align: center;
    font-size: 2em;
    margin-bottom: 30px;
    color: #333;
}

.package-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 25px;
}

.package-card {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 15px;
    text-align: center;
    border: 3px solid transparent;
    transition: all 0.3s ease;
    position: relative;
}

.package-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
}

.package-card.selected {
    border-color: #667eea;
    background: #f0f2ff;
}

.package-card.featured {
    border-color: #f39c12;
    background: linear-gradient(135deg, #fff9e6 0%, #ffe6cc 100%);
}

.badge {
    position: absolute;
    top: -10px;
    right: 10px;
    background: #f39c12;
    color: white;
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8em;
    font-weight: bold;
}

.package-card h3 {
    font-size: 1.5em;
    margin-bottom: 15px;
    color: #333;
}

.package-price {
    font-size: 2em;
    font-weight: bold;
    color: #667eea;
    margin-bottom: 10px;
}

.package-save {
    color: #27ae60;
    font-weight: bold;
    margin-bottom: 20px;
}

.btn-package {
    width: 100%;
    padding: 12px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease;
}

.btn-package:hover {
    background: #5568d3;
}

.selection {
    padding: 40px;
    background: #f8f9fa;
}

.selection h2 {
    text-align: center;
    font-size: 2em;
    margin-bottom: 30px;
    color: #333;
}

.selection-controls {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    margin-bottom: 20px;
    padding: 20px;
    background: white;
    border-radius: 10px;
}

.control-group {
    display: flex;
    gap: 10px;
    align-items: center;
}

.control-group label {
    font-weight: bold;
    color: #666;
}

#selected-package {
    font-weight: bold;
    color: #667eea;
    font-size: 1.1em;
}

.btn-random,
.btn-clear {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    cursor: pointer;
    transition: all 0.3s ease;
}

.btn-random {
    background: #27ae60;
    color: white;
}

.btn-random:hover {
    background: #229954;
}

.btn-clear {
    background: #e74c3c;
    color: white;
}

.btn-clear:hover {
    background: #c0392b;
}

.selected-numbers {
    background: white;
    padding: 20px;
    border-radius: 10px;
    margin-bottom: 20px;
    min-height: 60px;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
}

.selected-number-badge {
    background: #667eea;
    color: white;
    padding: 8px 15px;
    border-radius: 20px;
    font-weight: bold;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.remove-number {
    background: rgba(255, 255, 255, 0.3);
    border: none;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    cursor: pointer;
    font-size: 0.8em;
    display: flex;
    align-items: center;
    justify-content: center;
}

.remove-number:hover {
    background: rgba(255, 255, 255, 0.5);
}

.search-box {
    margin-bottom: 20px;
}

.search-box input {
    width: 100%;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
}

.search-box input:focus {
    outline: none;
    border-color: #667eea;
}

.numbers-grid {
    padding: 40px;
    background: white;
}

.grid-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
    gap: 20px;
}

.grid-header h2 {
    font-size: 2em;
    color: #333;
}

.pagination-controls {
    display: flex;
    align-items: center;
    gap: 15px;
}

.btn-nav {
    padding: 10px 20px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1em;
    transition: background 0.3s ease;
}

.btn-nav:hover:not(:disabled) {
    background: #5568d3;
}

.btn-nav:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.numbers-container {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(80px, 1fr));
    gap: 10px;
    max-height: 600px;
    overflow-y: auto;
    padding: 10px;
}

.number-item {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s ease;
    background: white;
    font-size: 0.9em;
}

.number-item:hover:not(.sold):not(.selected) {
    background: #f0f2ff;
    border-color: #667eea;
}

.number-item.sold {
    background: #e74c3c;
    color: white;
    cursor: not-allowed;
    opacity: 0.7;
}

.number-item.selected {
    background: #667eea;
    color: white;
    border-color: #5568d3;
}

.checkout {
    padding: 40px;
    background: #f8f9fa;
}

.checkout h2 {
    text-align: center;
    font-size: 2em;
    margin-bottom: 30px;
    color: #333;
}

.checkout-summary {
    background: white;
    padding: 30px;
    border-radius: 15px;
    margin-bottom: 30px;
}

.summary-item {
    display: flex;
    justify-content: space-between;
    padding: 15px 0;
    border-bottom: 1px solid #eee;
    font-size: 1.1em;
}

.summary-item.total {
    border-bottom: none;
    font-size: 1.5em;
    font-weight: bold;
    color: #667eea;
    margin-top: 10px;
}

.checkout-form {
    background: white;
    padding: 30px;
    border-radius: 15px;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #333;
}

.form-group input {
    width: 100%;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
    transition: border-color 0.3s ease;
}

.form-group input:focus {
    outline: none;
    border-color: #667eea;
}

.btn-checkout {
    width: 100%;
    padding: 15px;
    background: #27ae60;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1.2em;
    font-weight: bold;
    cursor: pointer;
    transition: background 0.3s ease;
    margin-top: 20px;
}

.btn-checkout:hover {
    background: #229954;
}

.payment-section {
    margin-top: 30px;
    padding: 30px;
    background: white;
    border-radius: 15px;
}

.payment-section h2 {
    text-align: center;
    font-size: 2em;
    margin-bottom: 20px;
    color: #333;
}

.pix-info {
    text-align: center;
}

.pix-instructions {
    font-size: 1.1em;
    color: #666;
    margin-bottom: 20px;
}

.pix-code-container {
    margin: 30px 0;
}

.pix-code-container label {
    display: block;
    font-weight: bold;
    margin-bottom: 10px;
    color: #333;
}

.pix-code-box {
    display: flex;
    flex-direction: column;
    gap: 15px;
    max-width: 800px;
    margin: 0 auto;
}

.pix-code-box textarea {
    width: 100%;
    padding: 15px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 0.9em;
    background: #f8f9fa;
    font-family: monospace;
    resize: vertical;
    min-height: 100px;
}

.pix-code-box textarea:focus {
    outline: none;
    border-color: #667eea;
}

.pix-key-container {
    margin: 30px 0;
}

.pix-key-container label {
    display: block;
    font-weight: bold;
    margin-bottom: 10px;
    color: #333;
}

.pix-key-box {
    display: flex;
    gap: 10px;
    max-width: 600px;
    margin: 0 auto;
}

.pix-key-box input {
    flex: 1;
    padding: 12px;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1em;
    background: #f8f9fa;
    font-family: monospace;
}

.pix-key-box input:focus {
    outline: none;
    border-color: #667eea;
}

.btn-copy {
    padding: 12px 20px;
    background: #667eea;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 1em;
    cursor: pointer;
    transition: background 0.3s ease;
    white-space: nowrap;
}

.btn-copy:hover {
    background: #5568d3;
}

.pix-amount {
    margin: 25px 0;
    padding: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 10px;
    color: white;
}

.pix-amount p {
    font-size: 1.3em;
    margin: 0;
}

.pix-amount span {
    font-size: 1.5em;
}

.pix-warning {
    margin-top: 20px;
    padding: 15px;
    background: #fff3cd;
    border: 2px solid #ffc107;
    border-radius: 8px;
    color: #856404;
}

.pix-warning p {
    margin: 0;
    font-size: 1em;
}

footer {
    text-align: center;
    padding: 20px;
    color: white;
    background: rgba(0, 0, 0, 0.3);
}

@media (max-width: 768px) {
    header h1 {
        font-size: 1.8em;
    }

    .prize-info {
        flex-direction: column;
    }

    .package-grid {
        grid-template-columns: 1fr;
    }

    .numbers-container {
        grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    }

    .grid-header {
        flex-direction: column;
        text-align: center;
    }

    .pix-key-box {
        flex-direction: column;
    }

    .pix-code-box {
        flex-direction: column;
    }

    .btn-copy {
        width: 100%;
    }
}

