/* Lifted verbatim from course.blade.php.
   Inline it was 29,565 bytes of HTML on every render;
   as a file the browser fetches it once. */
/* ============================================
   STUDENT PORTAL MODAL - FULL SCREEN APPLE UX
   Light/Dark Mode Compatible
   ============================================ */

/* Portal Modal Container - TRUE Full Screen */
.spm-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    max-width: none !important;
    max-height: none !important;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 9998;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 0 !important;
}
.spm-overlay.active {
    opacity: 1;
    visibility: visible;
}

.spm-modal {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    max-width: none !important;
    max-height: none !important;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    transition: all 0.35s cubic-bezier(0.32, 0.72, 0, 1);
    overflow: hidden;
    margin: 0 !important;
    padding: 0 !important;
    border-radius: 0 !important;
    /* Light mode default */
    background: #ffffff;
    color: #1d1d1f;
}
.spm-modal.active {
    opacity: 1;
    visibility: visible;
    transform: translateY(0) !important;
}

/* Dark mode support */
.dark .spm-modal {
    background: #000000;
    color: #f5f5f7;
}

/* Header - Frosted Glass */
.spm-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 28px;
    background: rgba(255, 255, 255, 0.72);
    backdrop-filter: saturate(180%) blur(20px);
    -webkit-backdrop-filter: saturate(180%) blur(20px);
    border-bottom: 1px solid rgba(0, 0, 0, 0.1);
    flex-shrink: 0;
    position: sticky;
    top: 0;
    z-index: 100;
}
.dark .spm-header {
    background: rgba(0, 0, 0, 0.72);
    border-bottom-color: rgba(255, 255, 255, 0.1);
}

.spm-header-left {
    display: flex;
    align-items: center;
    gap: 14px;
}

.spm-logo {
    width: 40px;
    height: 40px;
    background: linear-gradient(135deg, #3b82f6 0%, #2563eb 100%);
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}
.spm-logo svg {
    width: 20px;
    height: 20px;
    color: #fff;
}

.spm-title-group h2 {
    font-size: 17px;
    font-weight: 600;
    color: #1d1d1f !important;
    background: none !important;
    -webkit-text-fill-color: #1d1d1f !important;
    margin: 0 0 2px 0;
    letter-spacing: -0.01em;
}
.dark .spm-title-group h2 {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}
.spm-title-group p {
    font-size: 13px;
    color: #86868b;
    margin: 0;
}

.spm-close {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    background: rgba(0, 0, 0, 0.06);
    color: #1d1d1f;
    cursor: pointer;
    border-radius: 50%;
    transition: all 0.15s ease;
}
.spm-close:hover {
    background: rgba(0, 0, 0, 0.1);
}
.dark .spm-close {
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff;
}
.dark .spm-close:hover {
    background: rgba(255, 255, 255, 0.2);
}
.spm-close svg {
    width: 16px;
    height: 16px;
}

/* Main Layout */
.spm-body {
    display: flex;
    flex: 1;
    min-height: 0;
    overflow: hidden;
    background: #f5f5f7;
}
.dark .spm-body {
    background: #000000;
}

/* Sidebar - Light/Dark */
.spm-sidebar {
    width: 240px;
    background: #ffffff;
    border-right: 1px solid rgba(0, 0, 0, 0.08);
    padding: 20px 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
    flex-shrink: 0;
    overflow-y: auto;
}
.dark .spm-sidebar {
    background: #0a0a0a;
    border-right-color: rgba(255, 255, 255, 0.08);
}

.spm-nav-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 14px;
    border: none;
    background: transparent;
    color: #86868b;
    font-size: 14px;
    font-weight: 500;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.15s ease;
    text-align: left;
    width: 100%;
}
.dark .spm-nav-item {
    color: #8e8e93;
}
.spm-nav-item svg {
    width: 18px;
    height: 18px;
    opacity: 0.7;
    flex-shrink: 0;
}
.spm-nav-item:hover {
    background: rgba(0, 0, 0, 0.04);
    color: #1d1d1f;
}
.dark .spm-nav-item:hover {
    background: rgba(255, 255, 255, 0.06);
    color: #ffffff;
}
.spm-nav-item.active {
    background: #1d1d1f;
    color: #ffffff;
}
.dark .spm-nav-item.active {
    background: #ffffff;
    color: #000000;
}
.spm-nav-item.active svg {
    opacity: 1;
}

.spm-nav-divider {
    height: 1px;
    background: rgba(0, 0, 0, 0.08);
    margin: 12px 0;
}
.dark .spm-nav-divider {
    background: rgba(255, 255, 255, 0.08);
}

.spm-nav-label {
    font-size: 11px;
    font-weight: 600;
    color: #86868b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    padding: 16px 14px 8px;
}
.dark .spm-nav-label {
    color: #636366;
}

/* Content Area - Light/Dark */
.spm-content {
    flex: 1;
    padding: 32px 40px;
    background: #f5f5f7;
    overflow-y: auto;
    min-width: 0;
}
.dark .spm-content {
    background: #0a0a0a;
}

.spm-section {
    display: none;
}
.spm-section.active {
    display: block;
}

.spm-section-title {
    font-size: 24px;
    font-weight: 700;
    color: #1d1d1f !important;
    background: none !important;
    -webkit-text-fill-color: #1d1d1f !important;
    margin: 0 0 8px 0;
    letter-spacing: -0.02em;
}
.dark .spm-section-title {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}
.spm-section-desc {
    font-size: 15px;
    color: #86868b;
    margin: 0 0 28px 0;
    line-height: 1.5;
}
.dark .spm-section-desc {
    color: #8e8e93;
}

/* Toggle Switch - iOS Style */
.spm-toggle {
    position: relative;
    display: inline-block;
    width: 51px;
    height: 31px;
    flex-shrink: 0;
}
.spm-toggle input {
    opacity: 0;
    width: 0;
    height: 0;
}
.spm-toggle-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: #39393d;
    transition: all 0.3s ease;
    border-radius: 31px;
}
.spm-toggle-slider:before {
    position: absolute;
    content: "";
    height: 27px;
    width: 27px;
    left: 2px;
    bottom: 2px;
    background: #fff;
    transition: all 0.3s ease;
    border-radius: 50%;
    box-shadow: 0 2px 4px rgba(0,0,0,0.3);
}
.spm-toggle input:checked + .spm-toggle-slider {
    background: #30d158;
}
.spm-toggle input:checked + .spm-toggle-slider:before {
    transform: translateX(20px);
}

/* Small Toggle */
.spm-toggle-sm {
    width: 36px;
    height: 22px;
}
.spm-toggle-sm .spm-toggle-slider:before {
    height: 18px;
    width: 18px;
}
.spm-toggle-sm input:checked + .spm-toggle-slider:before {
    transform: translateX(14px);
}

/* Main Toggle Card - Light/Dark */
.spm-toggle-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 20px 24px;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 16px;
    margin-bottom: 24px;
    transition: all 0.2s ease;
}
.dark .spm-toggle-card {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-toggle-card.enabled {
    border-color: rgba(48, 209, 88, 0.5);
    background: rgba(48, 209, 88, 0.06);
}
.dark .spm-toggle-card.enabled {
    background: rgba(48, 209, 88, 0.08);
}

.spm-toggle-info {
    display: flex;
    align-items: center;
    gap: 16px;
}
.spm-toggle-icon {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f7;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 12px;
    flex-shrink: 0;
}
.dark .spm-toggle-icon {
    background: #2c2c2e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-toggle-icon svg {
    width: 24px;
    height: 24px;
    color: #86868b;
}
.dark .spm-toggle-icon svg {
    color: #8e8e93;
}
.spm-toggle-card.enabled .spm-toggle-icon {
    background: rgba(48, 209, 88, 0.15);
    border-color: rgba(48, 209, 88, 0.3);
}
.spm-toggle-card.enabled .spm-toggle-icon svg {
    color: #30d158;
}

/* How It Works Section - Light/Dark */
.spm-how-it-works {
    margin-top: 24px;
    padding: 20px 22px;
    background: #ffffff;
    border-radius: 14px;
    border: 1px solid rgba(0, 0, 0, 0.1);
}
.dark .spm-how-it-works {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-how-title {
    font-size: 14px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 14px;
    letter-spacing: -0.01em;
}
.dark .spm-how-title {
    color: #ffffff;
}
.spm-how-content {
    font-size: 14px;
    line-height: 1.6;
    color: #86868b;
    display: flex;
    flex-direction: column;
    gap: 12px;
}
.dark .spm-how-content {
    color: #8e8e93;
}
.spm-how-content strong {
    color: #1d1d1f;
}
.dark .spm-how-content strong {
    color: #ffffff;
}
.spm-how-options {
    margin-top: 6px;
    padding-left: 14px;
    border-left: 2px solid rgba(10, 132, 255, 0.5);
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.spm-toggle-text h4 {
    font-size: 15px;
    font-weight: 600;
    color: #1d1d1f !important;
    background: none !important;
    -webkit-text-fill-color: #1d1d1f !important;
    margin: 0 0 4px 0;
}
.dark .spm-toggle-text h4 {
    color: #ffffff !important;
    -webkit-text-fill-color: #ffffff !important;
}
.spm-toggle-text p {
    font-size: 13px;
    color: #86868b;
    margin: 0;
}
.dark .spm-toggle-text p {
    color: #8e8e93;
}

.spm-toggle-right {
    display: flex;
    align-items: center;
    gap: 12px;
}

.spm-status {
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.03em;
    padding: 5px 12px;
    border-radius: 100px;
}
.spm-status.active {
    background: rgba(48, 209, 88, 0.15);
    color: #30d158;
}
.spm-status.inactive {
    background: rgba(0, 0, 0, 0.06);
    color: #86868b;
}
.dark .spm-status.inactive {
    background: rgba(255, 255, 255, 0.08);
    color: #8e8e93;
}

/* Link Card - Light/Dark */
.spm-link-card {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 14px;
    padding: 18px 20px;
    margin-bottom: 16px;
}
.dark .spm-link-card {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}

.spm-link-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 14px;
}
.spm-link-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f7;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 10px;
    flex-shrink: 0;
}
.dark .spm-link-icon {
    background: #2c2c2e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-link-icon svg {
    width: 18px;
    height: 18px;
    color: #86868b;
}
.dark .spm-link-icon svg {
    color: #8e8e93;
}
.spm-link-title {
    font-size: 14px;
    font-weight: 600;
    color: #1d1d1f;
}
.dark .spm-link-title {
    color: #ffffff;
}

.spm-link-input-group {
    display: flex;
    gap: 10px;
}
.spm-link-input {
    flex: 1;
    padding: 12px 14px;
    font-size: 13px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    background: #f5f5f7;
    color: #1d1d1f;
    min-width: 0;
}
.dark .spm-link-input {
    border-color: rgba(255, 255, 255, 0.1);
    background: #000000;
    color: #ffffff;
}
.spm-link-input:focus {
    outline: none;
    border-color: #0a84ff;
    box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.2);
}

.spm-copy-btn {
    padding: 12px 18px;
    background: #1d1d1f;
    color: #ffffff;
    border: none;
    border-radius: 10px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: all 0.15s ease;
    flex-shrink: 0;
}
.dark .spm-copy-btn {
    background: #ffffff;
    color: #000000;
}
.spm-copy-btn:hover {
    transform: scale(1.02);
}
.spm-copy-btn svg {
    width: 14px;
    height: 14px;
}
.spm-copy-btn.copied {
    background: #30d158;
    color: #fff;
}

/* QR Code Section - Light/Dark */
.spm-qr-container {
    display: flex;
    align-items: center;
    gap: 24px;
    padding: 24px;
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 16px;
}
.dark .spm-qr-container {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-qr-code {
    width: 140px;
    height: 140px;
    background: #ffffff;
    border-radius: 12px;
    padding: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border: 1px solid rgba(0, 0, 0, 0.08);
}
.dark .spm-qr-code {
    border-color: transparent;
}
.spm-qr-info {
    flex: 1;
}
.spm-qr-info h4 {
    font-size: 15px;
    font-weight: 600;
    color: #1d1d1f;
    margin: 0 0 6px 0;
}
.dark .spm-qr-info h4 {
    color: #ffffff;
}
.spm-qr-info p {
    font-size: 13px;
    color: #86868b;
    margin: 0 0 16px 0;
}
.dark .spm-qr-info p {
    color: #8e8e93;
}
.spm-qr-clickable {
    cursor: pointer;
    transition: all 0.15s ease;
    text-decoration: none;
}
.spm-qr-clickable:hover {
    transform: scale(1.02);
    box-shadow: 0 4px 16px rgba(0,0,0,0.3);
}
.spm-qr-url {
    margin-bottom: 14px;
}
.spm-qr-url code {
    display: block;
    padding: 10px 14px;
    background: #f5f5f7;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    font-size: 12px;
    color: #86868b;
    word-break: break-all;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}
.dark .spm-qr-url code {
    background: #000000;
    border-color: rgba(255, 255, 255, 0.1);
    color: #8e8e93;
}
.spm-qr-buttons {
    display: flex;
    gap: 10px;
}

/* Assignment List */
.spm-assignment-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.spm-assignment-card {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 14px;
    overflow: hidden;
    transition: all 0.15s ease;
}
.dark .spm-assignment-card {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-assignment-card:hover {
    border-color: rgba(0, 0, 0, 0.2);
}
.dark .spm-assignment-card:hover {
    border-color: rgba(255, 255, 255, 0.2);
}
.spm-assignment-card.enabled {
    border-color: rgba(48, 209, 88, 0.4);
    background: rgba(48, 209, 88, 0.05);
}
.dark .spm-assignment-card.enabled {
    background: rgba(48, 209, 88, 0.05);
}

.spm-assignment-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
    cursor: pointer;
}
.spm-assignment-header:hover {
    background: rgba(0, 0, 0, 0.03);
}
.dark .spm-assignment-header:hover {
    background: rgba(255, 255, 255, 0.03);
}

.spm-assignment-info {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
    flex: 1;
}
.spm-assignment-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f7;
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 10px;
    flex-shrink: 0;
}
.dark .spm-assignment-icon {
    background: #2c2c2e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-assignment-icon svg {
    width: 18px;
    height: 18px;
    color: #86868b;
}
.dark .spm-assignment-icon svg {
    color: #8e8e93;
}
.spm-assignment-card.enabled .spm-assignment-icon {
    background: rgba(48, 209, 88, 0.15);
    border-color: rgba(48, 209, 88, 0.3);
}
.spm-assignment-card.enabled .spm-assignment-icon svg {
    color: #30d158;
}

.spm-assignment-name {
    font-size: 14px;
    font-weight: 600;
    color: #1d1d1f;
    margin: 0 0 3px 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.dark .spm-assignment-name {
    color: #ffffff;
}
.spm-assignment-meta {
    font-size: 12px;
    color: #86868b;
}
.dark .spm-assignment-meta {
    color: #8e8e93;
}

.spm-assignment-controls {
    display: flex;
    align-items: center;
    gap: 14px;
    flex-shrink: 0;
}

.spm-assignment-details {
    display: none;
    padding: 0 18px 18px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
}
.dark .spm-assignment-details {
    border-top-color: rgba(255, 255, 255, 0.08);
}
.spm-assignment-card.expanded .spm-assignment-details {
    display: block;
    padding-top: 18px;
}

.spm-detail-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.dark .spm-detail-row {
    border-bottom-color: rgba(255, 255, 255, 0.06);
}
.spm-detail-row:last-child {
    border-bottom: none;
}
.spm-detail-label {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 13px;
    color: #86868b;
}
.dark .spm-detail-label {
    color: #8e8e93;
}
.spm-detail-label svg {
    width: 16px;
    height: 16px;
}

.spm-date-input {
    padding: 10px 12px;
    font-size: 13px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    background: #f5f5f7;
    color: #1d1d1f;
}
.dark .spm-date-input {
    border-color: rgba(255, 255, 255, 0.1);
    background: #000000;
    color: #ffffff;
}
.spm-date-input:focus {
    outline: none;
    border-color: #0a84ff;
    box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.2);
}

/* Buttons - Light/Dark Theme */
.spm-btn {
    padding: 12px 20px;
    font-size: 14px;
    font-weight: 600;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.15s ease;
}
.spm-btn svg {
    width: 16px;
    height: 16px;
}
.spm-btn-primary {
    background: #1d1d1f;
    color: #ffffff;
}
.dark .spm-btn-primary {
    background: #ffffff;
    color: #000000;
}
.spm-btn-primary:hover {
    transform: scale(1.02);
}
.spm-btn-secondary {
    background: #f5f5f7;
    color: #1d1d1f;
    border: 1px solid rgba(0, 0, 0, 0.1);
}
.dark .spm-btn-secondary {
    background: #2c2c2e;
    color: #ffffff;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-btn-secondary:hover {
    background: #e8e8ed;
}
.dark .spm-btn-secondary:hover {
    background: #3a3a3c;
}
.spm-btn-sm {
    padding: 8px 14px;
    font-size: 12px;
    border-radius: 8px;
}

/* Button Group */
.spm-btn-group {
    display: flex;
    gap: 12px;
    margin-top: 20px;
}

/* Empty State - Light/Dark */
.spm-empty {
    text-align: center;
    padding: 64px 24px;
    color: #86868b;
}
.dark .spm-empty {
    color: #8e8e93;
}
.spm-empty-icon {
    width: 64px;
    height: 64px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f5f5f7;
    border-radius: 16px;
    margin: 0 auto 20px;
}
.dark .spm-empty-icon {
    background: #1c1c1e;
}
.spm-empty-icon svg {
    width: 28px;
    height: 28px;
    color: #86868b;
}
.dark .spm-empty-icon svg {
    color: #636366;
}
.spm-empty h4 {
    font-size: 15px;
    font-weight: 600;
    color: #1d1d1f;
    margin: 0 0 6px 0;
}
.dark .spm-empty h4 {
    color: #ffffff;
}
.spm-empty p {
    font-size: 14px;
    margin: 0;
}

/* Stats Grid - Light/Dark */
.spm-stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 28px;
}
.spm-stat-card {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 16px;
    padding: 20px;
    text-align: center;
}
.dark .spm-stat-card {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-stat-value {
    font-size: 32px;
    font-weight: 700;
    color: #1d1d1f;
    line-height: 1;
    margin-bottom: 6px;
    letter-spacing: -0.02em;
}
.dark .spm-stat-value {
    color: #ffffff;
}
.spm-stat-label {
    font-size: 12px;
    color: #86868b;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.dark .spm-stat-label {
    color: #8e8e93;
}

/* Footer - Light/Dark */
.spm-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 28px;
    border-top: 1px solid rgba(0, 0, 0, 0.08);
    background: #ffffff;
    flex-shrink: 0;
}
.dark .spm-footer {
    border-top-color: rgba(255, 255, 255, 0.08);
    background: #0a0a0a;
}
.spm-footer-text {
    font-size: 13px;
    color: #86868b;
    display: flex;
    align-items: center;
    gap: 8px;
}
.dark .spm-footer-text {
    color: #636366;
}
.spm-footer-text svg {
    width: 16px;
    height: 16px;
}

/* Responsive */
/* Settings Section Styles - Light/Dark */
.spm-settings-group {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 14px;
    padding: 20px;
    margin-bottom: 16px;
}
.dark .spm-settings-group {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-settings-header {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 14px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 16px;
    padding-bottom: 14px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}
.dark .spm-settings-header {
    color: #ffffff;
    border-bottom-color: rgba(255, 255, 255, 0.08);
}
.spm-setting-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}
.dark .spm-setting-row {
    border-bottom-color: rgba(255, 255, 255, 0.06);
}
.spm-setting-row:last-child {
    border-bottom: none;
    padding-bottom: 0;
}
.spm-setting-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}
.spm-setting-label {
    font-size: 14px;
    font-weight: 500;
    color: #1d1d1f;
}
.dark .spm-setting-label {
    color: #ffffff;
}
.spm-setting-desc {
    font-size: 13px;
    color: #86868b;
}
.dark .spm-setting-desc {
    color: #8e8e93;
}
.spm-select {
    padding: 10px 36px 10px 14px;
    font-size: 14px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    background: #f5f5f7 url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%2386868b' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E") no-repeat right 10px center;
    background-size: 18px;
    appearance: none;
    cursor: pointer;
    min-width: 120px;
    color: #1d1d1f;
}
.dark .spm-select {
    border-color: rgba(255, 255, 255, 0.1);
    background-color: #000000;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%238e8e93' stroke-width='2'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' d='M19 9l-7 7-7-7'/%3E%3C/svg%3E");
    color: #ffffff;
}
.spm-select:focus {
    outline: none;
    border-color: #0a84ff;
    box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.2);
}
.spm-text-input {
    width: 100%;
    padding: 12px 14px;
    font-size: 14px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    background: #f5f5f7;
    color: #1d1d1f;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.dark .spm-text-input {
    border-color: rgba(255, 255, 255, 0.1);
    background: #000000;
    color: #ffffff;
}
.spm-text-input:focus {
    outline: none;
    border-color: #0a84ff;
    box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.2);
}
.spm-text-input::placeholder {
    color: #86868b;
}
.dark .spm-text-input::placeholder {
    color: #636366;
}
.spm-textarea {
    width: 100%;
    padding: 12px 14px;
    font-size: 14px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    background: #f5f5f7;
    color: #1d1d1f;
    resize: vertical;
    min-height: 80px;
    font-family: inherit;
    transition: border-color 0.15s, box-shadow 0.15s;
}
.dark .spm-textarea {
    border-color: rgba(255, 255, 255, 0.1);
    background: #000000;
    color: #ffffff;
}
.spm-textarea:focus {
    outline: none;
    border-color: #0a84ff;
    box-shadow: 0 0 0 3px rgba(10, 132, 255, 0.2);
}
.spm-textarea::placeholder {
    color: #86868b;
}
.dark .spm-textarea::placeholder {
    color: #636366;
}
.spm-save-status {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: rgba(48, 209, 88, 0.1);
    border: 1px solid rgba(48, 209, 88, 0.2);
    border-radius: 12px;
    font-size: 14px;
    font-weight: 500;
    color: #30d158;
    margin-top: 20px;
}

/* Branding Section Styles - Dark Theme */
.spm-logo-upload-area {
    width: 100%;
}
.spm-logo-preview {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 20px 28px;
    background: #f5f5f7;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 14px;
}
.dark .spm-logo-preview {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-logo-preview img {
    max-height: 56px;
    max-width: 220px;
    object-fit: contain;
}
.spm-logo-remove {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 28px;
    height: 28px;
    background: #ff453a;
    color: #fff;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.15s ease;
}
.spm-logo-remove:hover {
    background: #ff6961;
    transform: scale(1.1);
}
.spm-logo-remove svg {
    width: 14px;
    height: 14px;
}
.spm-logo-dropzone {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 36px;
    background: #f5f5f7;
    border: 2px dashed rgba(0, 0, 0, 0.15);
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.15s ease;
}
.dark .spm-logo-dropzone {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.15);
}
.spm-logo-dropzone:hover {
    border-color: rgba(0, 0, 0, 0.3);
    background: #e8e8ed;
}
.dark .spm-logo-dropzone:hover {
    border-color: rgba(255, 255, 255, 0.3);
    background: #2c2c2e;
}
.spm-logo-dropzone svg {
    width: 36px;
    height: 36px;
    color: #86868b;
}
.dark .spm-logo-dropzone svg {
    color: #636366;
}
.spm-logo-dropzone span {
    font-size: 14px;
    color: #86868b;
}
.dark .spm-logo-dropzone span {
    color: #8e8e93;
}
.spm-logo-hint {
    font-size: 12px !important;
    color: #86868b !important;
}
.dark .spm-logo-hint {
    color: #636366 !important;
}

/* Color Picker */
.spm-color-picker-row {
    display: flex;
    align-items: center;
    gap: 10px;
}
.spm-color-input {
    width: 44px;
    height: 44px;
    padding: 3px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 10px;
    cursor: pointer;
    background: #f5f5f7;
}
.dark .spm-color-input {
    border-color: rgba(255, 255, 255, 0.1);
    background: #1c1c1e;
}
.spm-color-text {
    width: 110px !important;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace !important;
    text-transform: uppercase;
}
.spm-color-presets {
    display: flex;
    gap: 8px;
    margin-left: 10px;
}
.spm-color-preset {
    width: 28px;
    height: 28px;
    border: 2px solid transparent;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.15s ease;
}
.spm-color-preset:hover {
    transform: scale(1.15);
    border-color: rgba(0, 0, 0, 0.2);
}
.dark .spm-color-preset:hover {
    border-color: rgba(255, 255, 255, 0.4);
}

/* Branding Preview - Light/Dark Theme */
.spm-branding-preview {
    background: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.1);
    border-radius: 16px;
    overflow: hidden;
}
.dark .spm-branding-preview {
    background: #1c1c1e;
    border-color: rgba(255, 255, 255, 0.1);
}
.spm-preview-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 18px;
    background: #f5f5f7;
    border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}
.dark .spm-preview-header {
    background: #0a0a0a;
    border-bottom-color: rgba(255, 255, 255, 0.08);
}
.spm-preview-logo {
    display: flex;
    align-items: center;
    gap: 10px;
}
.spm-preview-logo img {
    height: 24px;
    width: auto;
    object-fit: contain;
}
.spm-preview-logo span {
    font-size: 15px;
    font-weight: 600;
    color: #1d1d1f;
}
.dark .spm-preview-logo span {
    color: #ffffff;
}
.spm-preview-badge {
    font-size: 12px;
    font-weight: 500;
    padding: 5px 12px;
    border-radius: 100px;
}
.spm-preview-body {
    padding: 24px 20px;
    text-align: center;
}
.spm-preview-title {
    font-size: 17px;
    font-weight: 600;
    color: #1d1d1f;
    margin-bottom: 14px;
}
.dark .spm-preview-title {
    color: #ffffff;
}
.spm-preview-btn {
    display: inline-block;
    padding: 10px 28px;
    font-size: 14px;
    font-weight: 600;
    color: #fff;
    border-radius: 10px;
}

@media (max-width: 768px) {
    .spm-sidebar {
        display: none;
    }
    .spm-content {
        padding: 24px 20px;
    }
    .spm-stats-grid {
        grid-template-columns: 1fr;
    }
    .spm-section-title {
        font-size: 20px;
    }
    .spm-toggle-card {
        flex-direction: column;
        align-items: flex-start;
        gap: 16px;
    }
    .spm-toggle-right {
        width: 100%;
        justify-content: space-between;
    }
}
