/**
 * Rs Christmas Santa - Admin Stylesheet
 * Modern, clean WordPress settings dashboard.
 */

.rs-xmas-admin-wrap {
    max-width: 1200px;
    margin: 20px 20px 0 0;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
}

.rs-xmas-header {
    background: linear-gradient(135deg, #184b41 0%, #226c5e 50%, #bc1d2b 100%);
    color: #ffffff;
    padding: 24px 28px;
    border-radius: 12px;
    margin-bottom: 20px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.rs-xmas-title h1 {
    margin: 0;
    font-size: 26px;
    font-weight: 800;
    color: #ffffff;
    display: flex;
    align-items: center;
    gap: 8px;
}

.rs-xmas-title .accent-red {
    color: #ffcccc;
}

.rs-xmas-title .badge-version {
    font-size: 12px;
    background: rgba(255, 255, 255, 0.2);
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 600;
}

.rs-xmas-title .subtitle {
    margin: 6px 0 0;
    font-size: 14px;
    color: rgba(255, 255, 255, 0.85);
}

/* Nav Tabs */
.rs-nav-tab-wrapper {
    display: flex !important;
    flex-wrap: wrap !important;
    gap: 4px 6px !important;
    align-items: flex-end !important;
    border-bottom: 2px solid #226c5e !important;
    margin-bottom: 20px !important;
    padding: 0 0 0 4px !important;
    position: relative;
    float: none !important;
}

.rs-nav-tab-wrapper::before,
.rs-nav-tab-wrapper::after {
    display: none !important;
}

.rs-nav-tab-wrapper .nav-tab {
    float: none !important;
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    font-size: 13.5px;
    font-weight: 600;
    padding: 8px 14px !important;
    border: 1px solid #cbd5e1 !important;
    border-bottom: none !important;
    background: #f8fafc !important;
    color: #475569 !important;
    border-radius: 8px 8px 0 0 !important;
    margin: 0 !important;
    transition: all 0.2s ease;
    line-height: 1.4 !important;
    height: 38px !important;
    box-sizing: border-box !important;
    white-space: nowrap !important;
}

.rs-nav-tab-wrapper .nav-tab:hover {
    background: #e2e8f0 !important;
    color: #0f172a !important;
}

.rs-nav-tab-wrapper .nav-tab.nav-tab-active {
    background: #226c5e !important;
    color: #ffffff !important;
    border-color: #226c5e !important;
    height: 40px !important;
    margin-bottom: -2px !important;
    position: relative;
    z-index: 2;
}

/* Two-column Layout */
.rs-xmas-main-layout {
    display: flex;
    gap: 24px;
    align-items: flex-start;
}

.rs-xmas-form-col {
    flex: 1;
    min-width: 0;
}

.rs-xmas-sidebar-col {
    width: 320px;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Cards */
.rs-xmas-card {
    background: #ffffff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 24px;
    box-shadow: 0 2px 6px rgba(0, 0, 0, 0.04);
}

.rs-card-header {
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 12px;
    margin-bottom: 16px;
}

.rs-card-header h3 {
    margin: 0;
    font-size: 16px;
    font-weight: 700;
    color: #1e293b;
}

/* Form Settings Tables */
.rs-xmas-card .form-table th {
    width: 220px;
    font-weight: 600;
    color: #334155;
    padding: 16px 12px 16px 0;
    vertical-align: top;
}

.rs-xmas-card .form-table td {
    padding: 14px 0;
}

.field-desc {
    display: block;
    margin-top: 6px;
    color: #64748b;
    font-size: 13px;
}

/* Switches (iOS Style) */
.rs-switch {
    position: relative;
    display: inline-block;
    width: 46px;
    height: 24px;
    vertical-align: middle;
}

.rs-switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.rs-slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #cbd5e1;
    transition: .3s;
    border-radius: 24px;
}

.rs-slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: .3s;
    border-radius: 50%;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

.rs-switch input:checked + .rs-slider {
    background-color: #226c5e;
}

.rs-switch input:checked + .rs-slider:before {
    transform: translateX(22px);
}

/* Radio Button Group */
.rs-radio-group {
    display: flex;
    gap: 12px;
}

.rs-radio-btn {
    border: 1px solid #cbd5e1;
    padding: 8px 16px;
    border-radius: 8px;
    background: #f8fafc;
    cursor: pointer;
    font-size: 13px;
    font-weight: 600;
    color: #334155;
    transition: all 0.2s ease;
}

.rs-radio-btn input {
    margin-right: 6px;
}

.rs-radio-btn:hover {
    border-color: #226c5e;
    background: #f0fdf4;
}

/* Grid Pickers (for Santa & Countdown styles) */
.rs-grid-picker {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(105px, 1fr));
    gap: 12px;
    max-height: 380px;
    overflow-y: auto;
    padding: 10px;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
}

.rs-picker-item {
    background: #ffffff;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    padding: 8px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.rs-picker-item input[type="radio"] {
    display: none;
}

.rs-picker-thumb {
    height: 70px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 6px;
}

.rs-picker-thumb img {
    max-height: 65px;
    max-width: 100%;
    object-fit: contain;
    transition: transform 0.2s ease;
}

.rs-picker-label {
    font-size: 11px;
    font-weight: 600;
    color: #475569;
    display: block;
}

.rs-picker-item:hover {
    border-color: #94a3b8;
}

.rs-picker-item:hover .rs-picker-thumb img {
    transform: scale(1.08);
}

.rs-picker-item.selected {
    border-color: #bc1d2b;
    background: #fff5f5;
    box-shadow: 0 0 0 1px #bc1d2b;
}

.rs-picker-item.selected .rs-picker-label {
    color: #bc1d2b;
    font-weight: 700;
}

/* Page Checklist Grid */
.rs-page-checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 8px;
    max-height: 200px;
    overflow-y: auto;
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 10px;
    margin-top: 8px;
}

.rs-checkbox-label {
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 6px;
    color: #334155;
}

/* Live Preview Sidebar Box */
.rs-live-preview-box {
    background: radial-gradient(circle at center, #1e293b 0%, #0f172a 100%);
    border-radius: 8px;
    padding: 20px;
    min-height: 180px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
    overflow: hidden;
    box-shadow: inset 0 2px 6px rgba(0, 0, 0, 0.4);
}

.preview-hint {
    font-size: 12px;
    color: #64748b;
    margin: 10px 0 0;
    text-align: center;
}

/* Quick Links in Sidebar */
.rs-quick-links {
    list-style: none;
    margin: 0;
    padding: 0;
}

.rs-quick-links li {
    padding: 8px 0;
    border-bottom: 1px solid #f1f5f9;
    font-size: 13px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.rs-quick-links li:last-child {
    border-bottom: none;
}

.rs-quick-links li.rs-quick-shortcode-item {
    display: flex;
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding-bottom: 12px;
}

.rs-shortcode-label {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13px;
    color: #1e293b;
}

.rs-shortcode-box {
    display: flex;
    align-items: center;
    background: #f8fafc;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    padding: 4px 6px 4px 8px;
    gap: 6px;
    max-width: 100%;
    box-sizing: border-box;
}

.rs-shortcode-box code {
    background: transparent !important;
    padding: 0 !important;
    font-size: 11px;
    color: #bc1d2b;
    word-break: break-all;
    flex: 1;
    cursor: pointer;
    font-family: Consolas, Monaco, monospace;
}

.rs-copy-btn {
    background: none;
    border: none;
    color: #64748b;
    cursor: pointer;
    padding: 4px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: all 0.2s ease;
}

.rs-copy-btn:hover {
    color: #226c5e;
    background: #e2e8f0;
}

.rs-copy-btn.copied {
    color: #16a34a;
}

.rs-quick-links a {
    color: #226c5e;
    text-decoration: none;
    font-weight: 600;
}

.rs-quick-links a:hover {
    color: #bc1d2b;
    text-decoration: underline;
}

/* Custom Work Section in Sidebar */
.rs-custom-work-section {
    margin-top: 18px;
    padding: 14px;
    background: linear-gradient(135deg, #f0fdf4 0%, #ecfdf5 100%);
    border: 1px solid #bbf7d0;
    border-radius: 8px;
}

.rs-custom-work-header {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 13.5px;
    color: #166534;
    margin-bottom: 6px;
}

.rs-custom-work-header .dashicons {
    color: #15803d;
    font-size: 17px;
    width: 17px;
    height: 17px;
}

.rs-custom-work-desc {
    font-size: 12px;
    line-height: 1.5;
    color: #374151;
    margin: 0 0 12px;
}

.rs-custom-work-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    width: 100%;
    box-sizing: border-box;
    background: #226c5e;
    color: #ffffff !important;
    padding: 7px 12px;
    font-size: 12.5px;
    font-weight: 600;
    text-decoration: none !important;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(34, 108, 94, 0.25);
    transition: all 0.2s ease;
}

.rs-custom-work-btn:hover {
    background: #195247;
    color: #ffffff !important;
    box-shadow: 0 2px 6px rgba(34, 108, 94, 0.4);
    transform: translateY(-1px);
}

.rs-custom-work-btn .dashicons {
    font-size: 14px;
    width: 14px;
    height: 14px;
}

/* Save Button */
.rs-save-btn {
    background: #226c5e !important;
    border-color: #226c5e !important;
    padding: 8px 24px !important;
    font-size: 14px !important;
    font-weight: 700 !important;
    border-radius: 6px !important;
    box-shadow: 0 2px 6px rgba(34, 108, 94, 0.3) !important;
}

.rs-save-btn:hover {
    background: #184b41 !important;
    border-color: #184b41 !important;
}

.rs-select {
    padding: 6px 12px;
    border-radius: 6px;
    border: 1px solid #cbd5e1;
    min-width: 220px;
}

.rs-color-input {
    width: 44px;
    height: 34px;
    border: 1px solid #cbd5e1;
    border-radius: 6px;
    cursor: pointer;
    vertical-align: middle;
}

/* Responsive */
@media (max-width: 900px) {
    .rs-xmas-main-layout {
        flex-direction: column;
    }
    .rs-xmas-sidebar-col {
        width: 100%;
    }
}