/* Santa Gift Giving Frontend Styles */

.sgg-registration-form {
    max-width: 800px;
    margin: 30px auto;
    padding: 30px;
    background: #fff;
    border: 1px solid #ddd;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.sgg-form-title {
    margin: 0 0 15px 0;
    font-size: 28px;
    font-weight: 600;
    color: #2271b1;
    text-align: center;
}

.sgg-form-description {
    margin: 0 0 25px 0;
    color: #666;
    line-height: 1.6;
    text-align: center;
}

.sgg-form {
    margin: 0;
}

.sgg-form h3 {
    margin-top: 25px;
    margin-bottom: 15px;
    color: #2271b1;
    border-bottom: 2px solid #2271b1;
    padding-bottom: 8px;
    font-size: 20px;
}

.sgg-form .form-table {
    width: 100%;
    margin-bottom: 20px;
}

.sgg-form .form-table th {
    width: 200px;
    padding: 12px 10px 12px 0;
    vertical-align: top;
    font-weight: 600;
}

.sgg-form .form-table td {
    padding: 12px 0;
}

.sgg-form input[type="text"],
.sgg-form input[type="email"],
.sgg-form input[type="tel"],
.sgg-form input[type="number"],
.sgg-form input[type="datetime-local"],
.sgg-form textarea,
.sgg-form select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.sgg-form input:focus,
.sgg-form textarea:focus,
.sgg-form select:focus {
    outline: none;
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
}

.sgg-form .description {
    font-size: 12px;
    color: #666;
    margin-top: 5px;
    line-height: 1.5;
}

.sgg-form .submit {
    margin-top: 30px;
    text-align: center;
}

.sgg-submit-btn {
    padding: 14px 30px;
    font-size: 16px;
    font-weight: 600;
    background: #2271b1;
    color: white;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.sgg-submit-btn:hover {
    background: #135e96;
}

.sgg-submit-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.sgg-message {
    padding: 15px;
    margin-bottom: 20px;
    border-radius: 4px;
    font-weight: 500;
}

.sgg-message.sgg-success {
    background: #d1e7dd;
    color: #0f5132;
    border: 1px solid #badbcc;
}

.sgg-message.sgg-error {
    background: #f8d7da;
    color: #842029;
    border: 1px solid #f5c2c7;
}

.sgg-edit-form-container {
    max-width: 1200px;
    margin: 20px auto;
    padding: 20px;
}

.sgg-registrations-table {
    width: 100%;
    border-collapse: collapse;
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.sgg-registrations-table th {
    background: #f5f5f5;
    padding: 12px;
    text-align: left;
    font-weight: bold;
    border-bottom: 2px solid #ddd;
}

.sgg-registrations-table td {
    padding: 12px;
    border-bottom: 1px solid #eee;
}

.sgg-registrations-table tr:hover {
    background: #f9f9f9;
}

.sgg-status {
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.sgg-status-pending {
    background: #fff3cd;
    color: #856404;
}

.sgg-status-selected {
    background: #d1e7dd;
    color: #0f5132;
}

.sgg-status-disqualified {
    background: #f8d7da;
    color: #842029;
}

.sgg-status-claimed {
    background: #cfe2ff;
    color: #084298;
}

/* Modal Styles */
.sgg-modal {
    display: none;
    position: fixed;
    z-index: 999999;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    overflow: auto;
    padding: 20px;
    box-sizing: border-box;
}

.sgg-modal-content {
    background-color: #fefefe;
    margin: 2% auto;
    padding: 0;
    border: 1px solid #888;
    border-radius: 5px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
    position: relative;
    max-width: 90%;
}

.sgg-modal-header {
    padding: 20px;
    background: #2271b1;
    color: white;
    border-radius: 5px 5px 0 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.sgg-modal-header h2 {
    margin: 0;
    color: white;
}

.sgg-modal-close {
    color: white;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
    line-height: 1;
}

.sgg-modal-close:hover {
    opacity: 0.7;
}

.sgg-modal-footer {
    padding: 20px;
    border-top: 1px solid #ddd;
    text-align: right;
}

.required {
    color: #d63638;
}

/* Status Dropdown */
.sgg-status-dropdown-frontend {
    padding: 4px 8px;
    border-radius: 3px;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid #ddd;
    cursor: pointer;
    min-width: 120px;
}

.sgg-status-dropdown-frontend:disabled {
    opacity: 0.6;
    cursor: wait;
}

/* Printable List Styles */
.sgg-printable-list-container {
    max-width: 1400px;
    margin: 20px auto;
    padding: 20px;
    background: #fff;
}

.sgg-printable-content {
    margin-top: 20px;
}

.sgg-screen-title {
    margin: 0 0 10px 0;
    color: #2271b1;
    font-size: 24px;
}

.sgg-screen-info {
    margin: 0 0 20px 0;
    color: #666;
    font-size: 14px;
}

.sgg-printable-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background: white;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
}

.sgg-printable-table th {
    background: #f5f5f5;
    padding: 12px 8px;
    text-align: left;
    font-weight: bold;
    border-bottom: 2px solid #ddd;
    font-size: 13px;
}

.sgg-printable-table td {
    padding: 10px 8px;
    border-bottom: 1px solid #eee;
    font-size: 13px;
}

.sgg-printable-table tr:hover {
    background: #f9f9f9;
}

/* Print Styles */
@media print {
    body {
        background: white;
    }
    
    .sgg-print-actions,
    .sgg-screen-title,
    .sgg-screen-info,
    .sgg-edit-form-container h2,
    .button,
    .sgg-edit-btn,
    .sgg-delete-btn,
    .sgg-status-dropdown-frontend,
    #sgg-frontend-edit-modal,
    .sgg-modal {
        display: none !important;
    }
    
    .sgg-print-header {
        display: block !important;
        margin-bottom: 20px;
        border-bottom: 2px solid #000;
        padding-bottom: 10px;
        page-break-after: avoid;
    }
    
    .sgg-print-header h1 {
        margin: 0 0 10px 0;
        font-size: 24px;
    }
    
    .sgg-printable-list-container,
    #sgg-frontend-printable-list,
    .sgg-printable-content {
        border: none;
        padding: 0;
        margin: 0;
        box-shadow: none;
    }
    
    .sgg-printable-table,
    .sgg-registrations-table {
        width: 100%;
        border-collapse: collapse;
        font-size: 10px;
    }
    
    .sgg-printable-table th,
    .sgg-printable-table td,
    .sgg-registrations-table th,
    .sgg-registrations-table td {
        border: 1px solid #000;
        padding: 6px 4px;
        text-align: left;
    }
    
    .sgg-printable-table th,
    .sgg-registrations-table th {
        background: #f0f0f0;
        font-weight: bold;
    }
    
    .sgg-printable-table tr,
    .sgg-registrations-table tr {
        page-break-inside: avoid;
    }
    
    .sgg-status {
        display: inline-block;
        padding: 2px 6px;
        border-radius: 2px;
        font-size: 10px;
    }
    
    @page {
        margin: 1cm;
    }
}

/* Responsive */
@media (max-width: 768px) {
    .sgg-registration-form {
        margin: 20px 15px;
        padding: 20px;
    }
    
    .sgg-form .form-table th {
        width: 100%;
        display: block;
        padding-bottom: 5px;
    }
    
    .sgg-form .form-table td {
        display: block;
        padding-top: 0;
    }
}
