/* Base Styling and Variables */
:root {
    --bg-dark: #0f111a;
    --bg-card: rgba(22, 28, 45, 0.6);
    --bg-input: rgba(15, 17, 26, 0.8);
    --border-color: rgba(255, 255, 255, 0.08);
    --border-hover: rgba(59, 130, 246, 0.4);
    
    --primary: #3b82f6;
    --primary-gradient: linear-gradient(135deg, #3b82f6 0%, #1d4ed8 100%);
    --primary-hover: #2563eb;
    
    --success: #10b981;
    --success-gradient: linear-gradient(135deg, #10b981 0%, #047857 100%);
    --danger: #ef4444;
    --danger-gradient: linear-gradient(135deg, #ef4444 0%, #b91c1c 100%);
    --warning: #f59e0b;
    
    --text-main: #f3f4f6;
    --text-muted: #9ca3af;
    --text-dark: #1f2937;
    
    --font-outfit: 'Outfit', 'Noto Sans KR', sans-serif;
    --transition-speed: 0.3s;
    --blur-strength: 12px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-main);
    font-family: var(--font-outfit);
    min-height: 100vh;
    overflow-x: hidden;
    background-image: 
        radial-gradient(at 10% 20%, rgba(59, 130, 246, 0.15) 0px, transparent 50%),
        radial-gradient(at 90% 80%, rgba(16, 185, 129, 0.1) 0px, transparent 50%);
}

/* App Container and Grid Layout */
.app-container {
    display: flex;
    min-height: 100vh;
}

/* Sidebar Navigation */
.sidebar {
    width: 260px;
    background: rgba(15, 23, 42, 0.85);
    backdrop-filter: blur(var(--blur-strength));
    border-right: 1px solid var(--border-color);
    display: flex;
    flex-direction: column;
    padding: 2rem 1.5rem;
    position: fixed;
    height: 100vh;
    z-index: 100;
}

.logo-area {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    margin-bottom: 3rem;
}

.logo-icon {
    font-size: 1.8rem;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: rotateIcon 4s ease infinite;
}

@keyframes rotateIcon {
    0%, 100% { transform: rotate(0deg) scale(1); }
    50% { transform: rotate(180deg) scale(1.1); }
}

.logo-text h2 {
    font-size: 1.4rem;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.logo-text h2 span {
    color: var(--primary);
    font-weight: 500;
}

.sub-status {
    font-size: 0.75rem;
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 0.4rem;
    margin-top: 0.2rem;
}

.pulse-dot {
    width: 6px;
    height: 6px;
    background-color: var(--success);
    border-radius: 50%;
    box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    animation: pulse 1.6s infinite;
}

@keyframes pulse {
    0% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.7);
    }
    70% {
        transform: scale(1);
        box-shadow: 0 0 0 6px rgba(16, 185, 129, 0);
    }
    100% {
        transform: scale(0.95);
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0);
    }
}

.nav-menu {
    display: flex;
    flex-direction: column;
    gap: 0.6rem;
    flex-grow: 1;
}

.nav-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.9rem 1.2rem;
    color: var(--text-muted);
    text-decoration: none;
    border-radius: 12px;
    font-weight: 500;
    transition: all var(--transition-speed) cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid transparent;
}

.nav-item:hover {
    color: var(--text-main);
    background: rgba(255, 255, 255, 0.03);
    border-color: rgba(255, 255, 255, 0.05);
    transform: translateX(4px);
}

.nav-item.active {
    color: var(--text-main);
    background: rgba(59, 130, 246, 0.15);
    border-color: rgba(59, 130, 246, 0.2);
    box-shadow: 0 4px 20px rgba(59, 130, 246, 0.1);
}

.nav-item i {
    font-size: 1.1rem;
    transition: transform var(--transition-speed);
}

.nav-item.active i {
    color: var(--primary);
    transform: scale(1.1);
}

.sidebar-footer {
    font-size: 0.75rem;
    color: var(--text-muted);
    text-align: center;
}

/* Main Content Area */
.main-content {
    flex-grow: 1;
    margin-left: 260px;
    padding: 2.5rem 3rem;
    width: calc(100% - 260px);
}

/* Tab Panels */
.tab-panel {
    display: none;
    animation: fadeIn var(--transition-speed) ease;
}

.tab-panel.active {
    display: block;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* Header Area */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2.5rem;
}

.header-titles h1 {
    font-size: 2rem;
    font-weight: 700;
    letter-spacing: -0.5px;
    margin-bottom: 0.4rem;
}

.header-titles p {
    color: var(--text-muted);
    font-size: 0.95rem;
}

.header-actions {
    display: flex;
    gap: 0.8rem;
}

/* General Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 0.8rem 1.4rem;
    border-radius: 12px;
    font-family: var(--font-outfit);
    font-size: 0.9rem;
    font-weight: 600;
    cursor: pointer;
    transition: all var(--transition-speed) cubic-bezier(0.4, 0, 0.2, 1);
    border: none;
}

.btn-primary {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(59, 130, 246, 0.3);
}

.btn-primary:hover {
    box-shadow: 0 6px 20px rgba(59, 130, 246, 0.45);
    transform: translateY(-2px);
}

.btn-secondary {
    background: rgba(255, 255, 255, 0.06);
    color: var(--text-main);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.btn-danger {
    background: var(--danger-gradient);
    color: white;
    box-shadow: 0 4px 15px rgba(239, 68, 68, 0.3);
}

.btn-danger:hover {
    box-shadow: 0 6px 20px rgba(239, 68, 68, 0.45);
    transform: translateY(-2px);
}

.btn-xs {
    padding: 0.4rem 0.8rem;
    font-size: 0.75rem;
    border-radius: 8px;
}

.btn-block {
    width: 100%;
}

.btn:disabled {
    opacity: 0.4;
    cursor: not-allowed;
    transform: none !important;
    box-shadow: none !important;
}

/* Stats Cards */
.list-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    margin-bottom: 2.5rem;
}

.stat-card {
    background: var(--bg-card);
    backdrop-filter: blur(var(--blur-strength));
    border: 1px solid var(--border-color);
    border-radius: 20px;
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    transition: transform var(--transition-speed);
}

.stat-card:hover {
    transform: translateY(-4px);
}

.stat-icon {
    width: 52px;
    height: 52px;
    border-radius: 14px;
    background: rgba(59, 130, 246, 0.1);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.4rem;
}

.stat-icon.sales {
    background: rgba(16, 185, 129, 0.1);
    color: var(--success);
}

.stat-icon.category {
    background: rgba(245, 158, 11, 0.1);
    color: var(--warning);
}

.stat-info .stat-label {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-info h3 {
    font-size: 1.5rem;
    font-weight: 700;
    margin-top: 0.2rem;
}

/* Products Grid & Loader */
.products-grid-container {
    min-height: 350px;
    position: relative;
}

.loading-spinner-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 6rem 0;
    gap: 1rem;
}

.spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-color);
    border-top: 4px solid var(--primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.empty-state {
    text-align: center;
    padding: 6rem 2rem;
}

.empty-state i {
    font-size: 4rem;
    color: var(--text-muted);
    opacity: 0.3;
    margin-bottom: 1.5rem;
}

.empty-state h3 {
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 0.4rem;
}

.empty-state p {
    color: var(--text-muted);
    font-size: 0.9rem;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
    gap: 1.8rem;
}

/* Product Card */
.product-card {
    background: var(--bg-card);
    backdrop-filter: blur(var(--blur-strength));
    border: 1px solid var(--border-color);
    border-radius: 20px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all var(--transition-speed) cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.product-card:hover {
    transform: translateY(-6px);
    border-color: var(--border-hover);
    box-shadow: 0 15px 35px rgba(59, 130, 246, 0.15);
}

.product-img-wrapper {
    position: relative;
    width: 100%;
    padding-top: 75%; /* 4:3 Aspect Ratio */
    background: #111827;
    overflow: hidden;
}

.product-img-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform var(--transition-speed);
}

.product-card:hover .product-img-wrapper img {
    transform: scale(1.05);
}

.status-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    padding: 0.3rem 0.7rem;
    border-radius: 8px;
    font-size: 0.7rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    backdrop-filter: blur(4px);
    z-index: 2;
}

.status-badge.sale {
    background: rgba(16, 185, 129, 0.2);
    color: #34d399;
    border: 1px solid rgba(16, 185, 129, 0.3);
}

.status-badge.nosale {
    background: rgba(156, 163, 175, 0.2);
    color: #d1d5db;
    border: 1px solid rgba(156, 163, 175, 0.3);
}

.status-badge.soldout {
    background: rgba(239, 68, 68, 0.2);
    color: #f87171;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.product-info {
    padding: 1.2rem;
    display: flex;
    flex-direction: column;
    flex-grow: 1;
}

.product-category-label {
    font-size: 0.75rem;
    color: var(--text-muted);
    font-weight: 500;
    margin-bottom: 0.4rem;
}

.product-title {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.8rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    height: 2.8rem;
}

.product-price-row {
    display: flex;
    align-items: baseline;
    gap: 0.6rem;
    margin-bottom: 1rem;
}

.product-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--text-main);
}

.product-price-org {
    font-size: 0.85rem;
    color: var(--text-muted);
    text-decoration: line-through;
}

.product-sku {
    font-size: 0.75rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.04);
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    border: 1px solid var(--border-color);
    align-self: flex-start;
    margin-bottom: 1.2rem;
}

.product-actions {
    display: flex;
    gap: 0.5rem;
    margin-top: auto;
    border-top: 1px solid var(--border-color);
    padding-top: 0.8rem;
}

.product-actions button {
    flex-grow: 1;
}

/* Pagination UI */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 0.4rem;
    margin-top: 3rem;
}

.page-btn {
    width: 38px;
    height: 38px;
    border-radius: 10px;
    background: var(--bg-card);
    border: 1px solid var(--border-color);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-weight: 600;
    transition: all var(--transition-speed);
}

.page-btn:hover {
    color: var(--text-main);
    border-color: var(--primary);
    background: rgba(59, 130, 246, 0.08);
}

.page-btn.active {
    background: var(--primary-gradient);
    border-color: var(--primary);
    color: white;
    box-shadow: 0 4px 10px rgba(59, 130, 246, 0.2);
}

.page-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* Registration Grid Layout */
.grid-form-layout {
    display: grid;
    grid-template-columns: 1.5fr 1fr;
    gap: 2.5rem;
    align-items: start;
}

.card {
    background: var(--bg-card);
    backdrop-filter: blur(var(--blur-strength));
    border: 1px solid var(--border-color);
    border-radius: 24px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

/* Form Styles */
.form-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.form-group.full-width {
    grid-column: span 2;
}

.form-group label {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--text-muted);
}

.form-group label .required {
    color: var(--danger);
    margin-left: 2px;
}

.form-group input, 
.form-group select, 
.form-group textarea {
    background-color: var(--bg-input);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 0.8rem 1rem;
    color: var(--text-main);
    font-family: var(--font-outfit);
    font-size: 0.95rem;
    transition: all var(--transition-speed);
}

.form-group input:focus, 
.form-group select:focus, 
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(59, 130, 246, 0.15);
}

.input-with-action {
    display: flex;
    gap: 0.6rem;
}

.input-with-action input {
    flex-grow: 1;
}

.input-tip {
    font-size: 0.75rem;
    color: var(--text-muted);
}

.form-actions {
    display: flex;
    justify-content: flex-end;
    gap: 0.8rem;
    margin-top: 2rem;
    border-top: 1px solid var(--border-color);
    padding-top: 1.5rem;
}

/* Preview Sticky Sidebar */
.preview-card-sticky {
    position: sticky;
    top: 2.5rem;
}

.preview-card-sticky h3 {
    margin-bottom: 0.4rem;
}

.preview-tip {
    font-size: 0.8rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

/* Shop Item Preview Graphic */
.shop-item-preview {
    background: #111827;
    border-radius: 20px;
    overflow: hidden;
    border: 1px solid var(--border-color);
    max-width: 320px;
    margin: 0 auto;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.25);
}

.preview-img-box {
    position: relative;
    width: 100%;
    padding-top: 75%;
    overflow: hidden;
}

.preview-img-box img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.preview-badge {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(59, 130, 246, 0.85);
    color: white;
    padding: 0.3rem 0.6rem;
    border-radius: 6px;
    font-size: 0.65rem;
    font-weight: 700;
    letter-spacing: 0.5px;
    backdrop-filter: blur(4px);
}

.preview-info {
    padding: 1.2rem;
}

.preview-category {
    font-size: 0.7rem;
    color: var(--text-muted);
    margin-bottom: 0.3rem;
    text-transform: uppercase;
}

.preview-title {
    font-size: 0.95rem;
    font-weight: 600;
    line-height: 1.4;
    margin-bottom: 0.6rem;
}

.preview-price-row {
    display: flex;
    align-items: baseline;
    gap: 0.5rem;
    margin-bottom: 0.8rem;
}

.preview-price {
    font-size: 1.1rem;
    font-weight: 700;
}

.preview-price-org {
    font-size: 0.8rem;
    color: var(--text-muted);
    text-decoration: line-through;
}

.preview-sku {
    font-size: 0.7rem;
    color: var(--text-muted);
    background: rgba(255, 255, 255, 0.04);
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    border: 1px solid var(--border-color);
    display: inline-block;
}

/* CSV Upload Area */
.batch-layout {
    display: grid;
    grid-template-columns: 1.2fr 1fr;
    gap: 2.5rem;
    margin-bottom: 2.5rem;
}

.guide-card h3 {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 1.2rem;
}

.guide-list {
    padding-left: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
    color: var(--text-muted);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
}

.guide-list li strong {
    color: var(--text-main);
}

.template-box {
    background: #0b0c10;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    padding: 1.2rem;
}

.template-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.8rem;
    font-size: 0.8rem;
    color: var(--text-muted);
}

.template-box pre {
    overflow-x: auto;
    font-family: monospace;
    font-size: 0.8rem;
    color: var(--success);
}

.upload-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 250px;
}

.drop-zone {
    border: 2px dashed rgba(255, 255, 255, 0.15);
    border-radius: 16px;
    padding: 3rem 1.5rem;
    text-align: center;
    cursor: pointer;
    transition: all var(--transition-speed);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 1rem;
    background: rgba(255, 255, 255, 0.01);
}

.drop-zone:hover, 
.drop-zone.drag-over {
    border-color: var(--primary);
    background: rgba(59, 130, 246, 0.05);
}

.drop-icon {
    font-size: 3rem;
    color: var(--primary);
    transition: transform var(--transition-speed);
}

.drop-zone:hover .drop-icon {
    transform: translateY(-4px);
}

.drop-text {
    font-size: 0.9rem;
    color: var(--text-muted);
}

.selected-filename {
    font-size: 0.85rem;
    font-weight: 600;
    color: var(--success);
    background: rgba(16, 185, 129, 0.1);
    padding: 0.4rem 1rem;
    border-radius: 20px;
    display: none;
}

.upload-actions {
    margin-top: 1.5rem;
}

/* Batch Results UI */
.batch-summary-stats {
    display: flex;
    gap: 2rem;
    margin: 1.5rem 0;
}

.batch-stat {
    padding: 1.5rem;
    border-radius: 16px;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.batch-stat.success {
    background: rgba(16, 185, 129, 0.1);
    border: 1px solid rgba(16, 185, 129, 0.2);
    color: var(--success);
}

.batch-stat.fail {
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.2);
    color: var(--danger);
}

.batch-stat .num {
    font-size: 2.2rem;
    font-weight: 700;
}

.batch-stat .label {
    font-size: 0.85rem;
    font-weight: 500;
    color: var(--text-muted);
    margin-top: 0.2rem;
}

.error-log-box {
    background: #0f111a;
    border-radius: 12px;
    padding: 1.2rem;
    border: 1px solid var(--border-color);
}

.error-log-box h4 {
    margin-bottom: 0.8rem;
    font-size: 0.9rem;
    color: var(--danger);
}

.error-list {
    list-style: none;
    max-height: 200px;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
    gap: 0.4rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

.error-list li {
    padding: 0.3rem 0.5rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.03);
}

/* Settings Forms */
.settings-card {
    max-width: 600px;
}

.settings-card h3 {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-bottom: 0.5rem;
}

.settings-desc {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 2rem;
}

.settings-help {
    margin-top: 2.5rem;
    border-top: 1px solid var(--border-color);
    padding-top: 1.5rem;
}

.settings-help h4 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.8rem;
}

.settings-help ol {
    padding-left: 1.2rem;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    font-size: 0.85rem;
    color: var(--text-muted);
}

/* Modal confirm styling */
.modal-backdrop {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(4px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-box {
    background: #161c2d;
    border: 1px solid var(--border-color);
    border-radius: 24px;
    width: 90%;
    max-width: 460px;
    padding: 1.8rem;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.3);
    animation: scaleIn 0.2s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes scaleIn {
    from { transform: scale(0.9); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.2rem;
}

.modal-close {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-size: 1.2rem;
    cursor: pointer;
}

.modal-body {
    color: var(--text-main);
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 1.8rem;
}

.warning-text {
    color: var(--danger);
    font-size: 0.85rem;
    font-weight: 500;
    margin-top: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 0.8rem;
}

/* Toast System */
#toast-container {
    position: fixed;
    top: 2rem;
    right: 2rem;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.toast {
    background: rgba(22, 28, 45, 0.9);
    border: 1px solid var(--border-color);
    border-radius: 12px;
    padding: 1rem 1.4rem;
    color: var(--text-main);
    display: flex;
    align-items: center;
    gap: 0.8rem;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
    min-width: 280px;
    max-width: 400px;
    backdrop-filter: blur(8px);
    animation: slideIn 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes slideIn {
    from { transform: translateX(100%); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

.toast.success {
    border-left: 4px solid var(--success);
}

.toast.error {
    border-left: 4px solid var(--danger);
}

.toast.success i {
    color: var(--success);
}

.toast.error i {
    color: var(--danger);
}

.toast-msg {
    font-size: 0.85rem;
    font-weight: 500;
}

.hidden {
    display: none !important;
}

/* URL Analyzer Styles */
.url-analyzer-group {
    background: rgba(59, 130, 246, 0.04);
    border: 1px dashed rgba(59, 130, 246, 0.2);
    padding: 1.2rem;
    border-radius: 16px;
    margin-bottom: 0.5rem;
    border-left: 4px solid var(--primary);
}

.url-analyzer-group label {
    color: var(--primary) !important;
    font-weight: 700 !important;
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.analyzer-status {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    margin-top: 0.8rem;
    font-size: 0.85rem;
    color: var(--warning);
    background: rgba(245, 158, 11, 0.08);
    padding: 0.5rem 1rem;
    border-radius: 8px;
    border: 1px solid rgba(245, 158, 11, 0.15);
}

.spinner-small {
    width: 16px;
    height: 16px;
    border: 2px solid rgba(245, 158, 11, 0.2);
    border-top: 2px solid var(--warning);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    display: inline-block;
}

/* Description Header and Toggle Buttons */
.description-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.viewer-toggle-buttons {
    display: flex;
    background: rgba(255, 255, 255, 0.04);
    border-radius: 8px;
    padding: 0.2rem;
    border: 1px solid var(--border-color);
}

.toggle-btn {
    background: transparent;
    border: none;
    color: var(--text-muted);
    font-family: var(--font-outfit);
    font-size: 0.75rem;
    font-weight: 600;
    padding: 0.4rem 0.8rem;
    border-radius: 6px;
    cursor: pointer;
    transition: all var(--transition-speed);
    display: flex;
    align-items: center;
    gap: 0.4rem;
}

.toggle-btn:hover {
    color: var(--text-main);
}

.toggle-btn.active {
    background: var(--primary-gradient);
    color: white;
    box-shadow: 0 2px 6px rgba(59, 130, 246, 0.25);
}

.description-inputs-wrapper {
    position: relative;
    width: 100%;
}

.preview-viewer-box {
    background: #ffffff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    height: 250px;
    overflow: hidden;
    padding: 0;
    box-shadow: inset 0 2px 8px rgba(0,0,0,0.05);
}

.preview-iframe {
    width: 100%;
    height: 100%;
    border: none;
    background: #ffffff;
}

/* Premium Image Preview Hover Effects */
.preview-img-box {
    cursor: pointer;
    transition: filter var(--transition-speed);
}

.preview-img-box:hover {
    filter: brightness(0.95);
}

