/* Frontend Form Styles */
.sra-form {
    max-width: 800px;
    margin: 40px auto;
    padding: 40px;
    font-family: 'Segoe UI', system-ui, -apple-system, sans-serif;
    background: #ffffff;
    box-shadow: 0 4px 24px rgba(0, 0, 0, 0.06);
    border-radius: 12px;
}

.sra-form .sra-form-section {
    margin-bottom: 40px;
    padding: 30px;
    background: #f8fafc;
    border-radius: 10px;
    border: 1px solid #edf2f7;
    transition: all 0.3s ease;
}

.sra-form .sra-form-section:hover {
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.04);
    border-color: #e2e8f0;
    transform: translateY(-1px);
}

.sra-form .sra-form-section h2 {
    margin: 0 0 30px 0;
    color: #1a365d;
    font-size: 1.5em;
    padding-bottom: 15px;
    border-bottom: 2px solid #e2e8f0;
    font-weight: 600;
    letter-spacing: -0.02em;
}

.sra-form .sra-form-group {
    margin-bottom: 28px;
}

.sra-form .sra-form-group:last-child {
    margin-bottom: 0;
}

.sra-form .sra-form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 500;
    color: #2d3748;
    font-size: 0.95em;
    letter-spacing: 0.01em;
    line-height: 1.4;
}

.sra-form .sra-form-group input[type="text"],
.sra-form .sra-form-group input[type="email"],
.sra-form .sra-form-group input[type="tel"],
.sra-form .sra-form-group input[type="date"],
.sra-form .sra-form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    box-sizing: border-box;
    font-size: 15px;
    line-height: 1.5;
    transition: all 0.2s ease;
    background-color: #ffffff;
    color: #2d3748;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}

.sra-form .sra-form-group input:hover,
.sra-form .sra-form-group textarea:hover {
    border-color: #cbd5e0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

.sra-form .sra-form-group input:focus,
.sra-form .sra-form-group textarea:focus {
    border-color: #4299e1;
    outline: none;
    box-shadow: 0 0 0 3px rgba(66, 153, 225, 0.15);
    background-color: #ffffff;
}

.sra-form .sra-form-group textarea {
    resize: vertical;
    min-height: 120px;
    line-height: 1.6;
}

.sra-form .sra-radio-group,
.sra-form .sra-checkbox-group {
    margin-top: 12px;
}

.sra-form .sra-radio-group label,
.sra-form .sra-checkbox-group label {
    display: inline;
    font-weight: normal;
    margin-right: 24px;
    cursor: pointer;
    color: #4a5568;
    font-size: 0.95em;
    line-height: 1.6;
    transition: color 0.2s ease;
}

.sra-form .sra-radio-group label:hover,
.sra-form .sra-checkbox-group label:hover {
    color: #2d3748;
}

.sra-form .sra-radio-group input[type="radio"],
.sra-form .sra-checkbox-group input[type="checkbox"] {
    margin-right: 8px;
    transform: scale(1.1);
    cursor: pointer;
}

.sra-form .sra-required {
    color: #e53e3e;
    margin-left: 4px;
    font-size: 0.9em;
}

.sra-form .sra-form-submit {
    text-align: center;
    margin-top: 45px;
}

.sra-form .sra-form-submit input[type="submit"] {
    background-color: #2271b1;
    color: white;
    padding: 16px 40px;
    border: none;
    border-radius: 6px;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(34, 113, 177, 0.1);
    letter-spacing: 0.01em;
}

.sra-form .sra-form-submit input[type="submit"]:hover {
    background-color: #135e96;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(34, 113, 177, 0.2);
}

.sra-form .sra-form-submit input[type="submit"]:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(34, 113, 177, 0.1);
}

/* Error states */
.sra-form .sra-form-group input.sra-error,
.sra-form .sra-form-group textarea.sra-error {
    border-color: #e53e3e;
    background-color: #fff5f5;
}

.sra-form .sra-error-message {
    color: #e53e3e;
    font-size: 0.875em;
    margin-top: 8px;
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: #fff5f5;
    border-radius: 4px;
    border: 1px solid #feb2b2;
}

.sra-form .sra-error-message::before {
    content: "!";
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    background-color: #e53e3e;
    color: white;
    border-radius: 50%;
    font-size: 12px;
    font-weight: bold;
}

/* Success message and MP Letter section */
.sra-form .sra-success-message {
    background-color: #00a32a;
    color: white;
    padding: 24px;
    border-radius: 12px;
    margin-bottom: 35px;
    text-align: center;
    font-weight: 500;
    box-shadow: 0 3px 12px rgba(0, 163, 42, 0.15);
    position: relative;
    overflow: hidden;
}

.sra-form .sra-success-message::before {
    content: "✓";
    position: absolute;
    top: -15px;
    right: -15px;
    font-size: 100px;
    opacity: 0.1;
    line-height: 1;
    font-weight: bold;
}

.sra-form .mp-letter-section {
    background: #f8fafc;
    padding: 30px;
    border-radius: 12px;
    border: 1px solid #e2e8f0;
    margin-top: 40px;
    position: relative;
}

.sra-form .mp-letter-section::before {
    content: "";
    position: absolute;
    top: -20px;
    left: 50%;
    transform: translateX(-50%);
    width: 40px;
    height: 40px;
    background: #fff url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 24 24" fill="%232271b1"><path d="M20 4H4c-1.1 0-2 .9-2 2v12c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V6c0-1.1-.9-2-2-2zm0 14H4V8l8 5 8-5v10zm-8-7L4 6h16l-8 5z"/></svg>') center/24px no-repeat;
    border: 1px solid #e2e8f0;
    border-radius: 50%;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.sra-form .mp-letter-section h3 {
    color: #1a365d;
    font-size: 1.4em;
    margin: 0 0 20px;
    text-align: center;
    font-weight: 600;
}

.sra-form .mp-letter-section p {
    color: #4a5568;
    line-height: 1.6;
    margin: 0 0 25px;
    text-align: center;
}

.sra-form .mp-letter-button {
    display: inline-block;
    background-color: #2271b1;
    color: white;
    padding: 16px 32px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: all 0.2s ease;
    box-shadow: 0 2px 4px rgba(34, 113, 177, 0.1);
    border: none;
    cursor: pointer;
    font-size: 15px;
    width: 100%;
    text-align: center;
}

.sra-form .mp-letter-button:hover {
    background-color: #135e96;
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(34, 113, 177, 0.2);
}

.sra-form .mp-letter-button:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(34, 113, 177, 0.1);
}

/* Admin Panel Styles */
body.toplevel_page_sra-registrations .sra-wp-list-table {
    border-collapse: separate;
    border-spacing: 0;
    margin-top: 20px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    overflow: hidden;
}

body.toplevel_page_sra-registrations .sra-wp-list-table th {
    padding: 14px 16px;
    text-align: left;
    font-weight: 600;
    color: #1d2327;
    border-bottom: 2px solid #e2e8f0;
    background: #f8fafc;
    white-space: nowrap;
    transition: background-color 0.2s ease;
}

body.toplevel_page_sra-registrations .sra-wp-list-table th:hover {
    background: #f1f5f9;
}

body.toplevel_page_sra-registrations .sra-wp-list-table td {
    padding: 14px 16px;
    vertical-align: middle;
    border-bottom: 1px solid #f0f0f1;
    color: #2c3338;
    transition: background-color 0.2s ease;
}

body.toplevel_page_sra-registrations .sra-wp-list-table tr:hover td {
    background-color: #f8fafc;
}

body.toplevel_page_sra-registrations .sra-wp-list-table tr:last-child td {
    border-bottom: none;
}

/* Bulk Actions Styling */
body.toplevel_page_sra-registrations .sra-tablenav.top {
    margin: 20px 0;
    padding: 0;
    display: flex;
    align-items: center;
    gap: 12px;
}

body.toplevel_page_sra-registrations .sra-bulkactions {
    display: flex;
    gap: 8px;
    align-items: center;
}

body.toplevel_page_sra-registrations .sra-bulk-action-selector-top {
    min-width: 200px;
    height: 36px;
    padding: 0 32px 0 12px;
    border: 1.5px solid #e2e8f0;
    border-radius: 6px;
    background-color: #fff;
    color: #1d2327;
    font-size: 13px;
    cursor: pointer;
    background-image: url('data:image/svg+xml;charset=US-ASCII,<svg width="20" height="20" xmlns="http://www.w3.org/2000/svg"><path d="M5 8l5 5 5-5z" fill="%23555"/></svg>');
    background-repeat: no-repeat;
    background-position: right 8px center;
    background-size: 20px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
    transition: all 0.2s ease;
}

body.toplevel_page_sra-registrations .sra-bulk-action-selector-top:hover {
    border-color: #cbd5e0;
    background-color: #f8fafc;
}

body.toplevel_page_sra-registrations .sra-bulk-action-selector-top:focus {
    border-color: #2271b1;
    box-shadow: 0 0 0 1px #2271b1;
    outline: none;
}

/* Action Buttons */
body.toplevel_page_sra-registrations .sra-action-buttons {
    display: flex;
    gap: 8px;
    align-items: center;
    justify-content: flex-end;
    min-width: 140px;
}

body.toplevel_page_sra-registrations .sra-action-buttons .sra-button {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    height: 32px;
    line-height: 1;
    font-size: 13px;
    border-radius: 6px;
    border: 1.5px solid transparent;
    transition: all 0.2s ease;
    cursor: pointer;
}

body.toplevel_page_sra-registrations .sra-action-buttons .sra-button .dashicons {
    font-size: 16px;
    width: 16px;
    height: 16px;
    transition: transform 0.2s ease;
}

body.toplevel_page_sra-registrations .sra-button.sra-button-primary {
    background: #2271b1;
    border-color: #2271b1;
    color: #fff;
    box-shadow: 0 1px 2px rgba(34, 113, 177, 0.1);
}

body.toplevel_page_sra-registrations .sra-button.sra-button-primary:hover {
    background: #135e96;
    border-color: #135e96;
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(34, 113, 177, 0.2);
}

body.toplevel_page_sra-registrations .sra-button.sra-export-registration {
    background: #fff;
    border-color: #2271b1;
    color: #2271b1;
}

body.toplevel_page_sra-registrations .sra-button.sra-export-registration:hover {
    background: #f0f9ff;
    transform: translateY(-1px);
}

body.toplevel_page_sra-registrations .sra-button.sra-button-link-delete {
    color: #d63638;
    border: none;
    background: none;
    padding: 6px;
    min-width: 32px;
    justify-content: center;
}

body.toplevel_page_sra-registrations .sra-button.sra-button-link-delete:hover {
    color: #b32d2e;
    background: #fff5f5;
    transform: translateY(-1px);
}

body.toplevel_page_sra-registrations .sra-button.sra-button-link-delete .dashicons {
    font-size: 18px;
    width: 18px;
    height: 18px;
    margin: 0;
}

/* Modal Styles */
.sra-registration-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 100000;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.sra-registration-modal.active {
    opacity: 1;
}

.sra-modal-content {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.95);
    background: white;
    border-radius: 12px;
    max-width: 800px;
    width: 90%;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    transition: transform 0.3s ease;
}

.sra-registration-modal.active .sra-modal-content {
    transform: translate(-50%, -50%) scale(1);
}

.sra-modal-header {
    padding: 20px 24px;
    border-bottom: 1px solid #e2e8f0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: #fff;
    border-radius: 12px 12px 0 0;
}

.sra-modal-header h2 {
    margin: 0;
    font-size: 1.4em;
    line-height: 1.4;
    color: #1d2327;
    font-weight: 600;
}

.sra-modal-close {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    color: #64748b;
    transition: all 0.2s ease;
    border-radius: 6px;
}

.sra-modal-close:hover {
    color: #1d2327;
    background: #f1f5f9;
}

.sra-modal-body {
    padding: 24px;
    overflow-y: auto;
    flex-grow: 1;
    background: #f8fafc;
}

.sra-modal-footer {
    padding: 20px 24px;
    border-top: 1px solid #e2e8f0;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    background: #fff;
    border-radius: 0 0 12px 12px;
}

.sra-registration-details {
    line-height: 1.6;
}

.sra-registration-details p {
    margin: 10px 0;
    padding: 14px 18px;
    background: #fff;
    border-radius: 8px;
    border: 1px solid #e2e8f0;
    transition: all 0.2s ease;
}

.sra-registration-details p:hover {
    border-color: #cbd5e0;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
}

.sra-registration-details strong {
    color: #1d2327;
    min-width: 150px;
    display: inline-block;
    font-weight: 600;
}

/* Responsive design */
@media (max-width: 782px) {
    .sra-form {
        padding: 20px;
        margin: 20px auto;
    }
    
    .sra-form .sra-form-section {
        padding: 20px;
        margin-bottom: 30px;
    }
    
    .sra-form .sra-form-group input[type="text"],
    .sra-form .sra-form-group input[type="email"],
    .sra-form .sra-form-group input[type="tel"],
    .sra-form .sra-form-group input[type="date"],
    .sra-form .sra-form-group textarea {
        font-size: 16px;
        padding: 10px 14px;
    }
    
    .sra-form .sra-form-submit input[type="submit"] {
        width: 100%;
        padding: 14px 20px;
    }

    body.toplevel_page_sra-registrations .sra-wp-list-table td {
        padding: 10px 12px;
    }
    
    body.toplevel_page_sra-registrations .sra-action-buttons {
        min-width: auto;
    }
    
    body.toplevel_page_sra-registrations .sra-action-buttons .sra-button {
        padding: 6px;
        min-width: 32px;
    }
    
    body.toplevel_page_sra-registrations .sra-action-buttons .sra-button .dashicons {
        margin: 0;
    }
    
    body.toplevel_page_sra-registrations .sra-action-buttons .sra-button span:not(.dashicons) {
        display: none;
    }
    
    .sra-modal-content {
        width: 95%;
        max-height: 95vh;
    }

    body.toplevel_page_sra-registrations .sra-bulk-action-selector-top {
        height: 40px;
    }
}
