/* styles.css */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

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

:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #8b5cf6;
    --secondary-color: #ec4899;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --danger-color: #ef4444;
    --info-color: #06b6d4;
    --dark-color: #111827;
    --light-color: #f8fafc;
    --text-color: #374151;
    --text-light: #6b7280;
    --border-color: #e5e7eb;
    --bg-color: #ffffff;
    --card-bg: #ffffff;
    --input-bg: #ffffff;
    --gradient-primary: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    --gradient-secondary: linear-gradient(135deg, #ec4899 0%, #f59e0b 100%);
    --shadow: 0 1px 3px rgba(0,0,0,0.1);
    --shadow-lg: 0 10px 25px -5px rgba(0,0,0,0.1);
    --shadow-xl: 0 20px 50px -12px rgba(0,0,0,0.25);
    --shadow-2xl: 0 25px 50px -12px rgba(0,0,0,0.35);
}

.dark-theme {
    --primary-color: #818cf8;
    --primary-dark: #6366f1;
    --primary-light: #a78bfa;
    --secondary-color: #f472b6;
    --success-color: #34d399;
    --warning-color: #fbbf24;
    --danger-color: #f87171;
    --info-color: #22d3ee;
    --dark-color: #0f172a;
    --light-color: #1e293b;
    --text-color: #f1f5f9;
    --text-light: #cbd5e1;
    --border-color: #334155;
    --bg-color: #0f172a;
    --card-bg: #1e293b;
    --input-bg: #334155;
    --gradient-primary: linear-gradient(135deg, #818cf8 0%, #a78bfa 100%);
    --gradient-secondary: linear-gradient(135deg, #f472b6 0%, #fbbf24 100%);
    --shadow: 0 1px 3px rgba(0,0,0,0.3);
    --shadow-lg: 0 10px 25px -5px rgba(0,0,0,0.3);
    --shadow-xl: 0 20px 50px -12px rgba(0,0,0,0.5);
    --shadow-2xl: 0 25px 50px -12px rgba(0,0,0,0.6);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--bg-color);
    min-height: 100vh;
    padding: 0;
    color: var(--text-color);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    line-height: 1.6;
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(99, 102, 241, 0.03) 0%, transparent 50%),
        radial-gradient(circle at 85% 30%, rgba(236, 72, 153, 0.03) 0%, transparent 50%);
}

.dark-theme body {
    background-image: 
        radial-gradient(circle at 15% 50%, rgba(99, 102, 241, 0.08) 0%, transparent 50%),
        radial-gradient(circle at 85% 30%, rgba(236, 72, 153, 0.08) 0%, transparent 50%);
}

/* Header Styles */
.header {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    box-shadow: var(--shadow-2xl);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.dark-theme .header {
    background: rgba(15, 23, 42, 0.9);
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 0.25rem;
    text-shadow: var(--shadow);
}

.logo p {
    font-size: 0.875rem;
    color: var(--text-light);
    font-weight: 400;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.user-info-header {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.5rem 1rem;
    background: var(--light-color);
    border-radius: 12px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
}

.username {
    font-weight: 600;
    color: var(--text-color);
    font-size: 0.875rem;
}

.btn-logout {
    background: linear-gradient(135deg, var(--danger-color), #dc2626);
    color: white;
    border: none;
    padding: 0.625rem 1.25rem;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    box-shadow: var(--shadow-lg);
}

.btn-logout:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-xl);
    background: linear-gradient(135deg, #dc2626, #b91c1c);
}

.theme-toggle {
    background: var(--light-color);
    border: 1px solid var(--border-color);
    color: var(--text-color);
    padding: 0.625rem;
    border-radius: 10px;
    cursor: pointer;
    font-size: 0.875rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
    box-shadow: var(--shadow);
}

.theme-toggle:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 2rem auto;
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(20px);
    padding: 2.5rem;
    border-radius: 20px;
    box-shadow: var(--shadow-2xl);
    border: 1px solid rgba(255, 255, 255, 0.2);
    position: relative;
    overflow: hidden;
}

.dark-theme .container {
    background: rgba(15, 23, 42, 0.8);
    border: 1px solid rgba(255, 255, 255, 0.1);
}

/* Dashboard Navigation */
.dashboard-nav {
    display: flex;
    gap: 1rem;
    margin-bottom: 2.5rem;
    padding: 1rem;
    background: var(--light-color);
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
}

.nav-item {
    flex: 1;
    padding: 1.5rem 1rem;
    text-align: center;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: transparent;
    border: 2px solid transparent;
}

.nav-item.active {
    background: var(--gradient-primary);
    color: white;
    box-shadow: var(--shadow-lg);
    border-color: var(--primary-color);
}

.nav-item:not(.active):hover {
    background: rgba(99, 102, 241, 0.1);
    border-color: var(--border-color);
}

.nav-icon {
    font-size: 2rem;
    margin-bottom: 0.5rem;
}

.nav-text {
    font-weight: 600;
    font-size: 0.875rem;
}

/* Dashboard Sections */
.dashboard-section {
    display: none;
    animation: fadeIn 0.5s ease;
}

.dashboard-section.active {
    display: block;
}

.section-header {
    text-align: center;
    margin-bottom: 2.5rem;
}

.section-header h1 {
    color: var(--text-color);
    margin-bottom: 0.5rem;
    font-size: 2rem;
    font-weight: 700;
}

.section-header p {
    color: var(--text-light);
    font-size: 1rem;
}

/* Dashboard Cards */
.dashboard-card {
    background: var(--light-color);
    padding: 2.5rem;
    border-radius: 16px;
    text-align: center;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-xl);
    transition: all 0.3s ease;
    margin-bottom: 2rem;
}

.dashboard-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-2xl);
}

.card-icon {
    font-size: 3rem;
    margin-bottom: 1rem;
}

.dashboard-card h3 {
    color: var(--text-color);
    margin-bottom: 1rem;
    font-size: 1.25rem;
    font-weight: 600;
}

.dashboard-card p {
    color: var(--text-light);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

/* Settings Styles */
.settings-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.settings-nav {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    padding: 0.5rem;
    background: var(--light-color);
    border-radius: 12px;
    border: 1px solid var(--border-color);
}

.settings-nav .nav-item {
    flex: 1;
    padding: 1rem 1.5rem;
    text-align: center;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
}

.settings-nav .nav-item.active {
    background: var(--gradient-primary);
    color: white;
}

.settings-content {
    background: var(--bg-color);
    border-radius: 16px;
    padding: 2rem;
    box-shadow: var(--shadow-lg);
    border: 1px solid var(--border-color);
}

.settings-section {
    display: none;
}

.settings-section.active {
    display: block;
}

/* Settings Cards */
.settings-card {
    background: var(--light-color);
    border-radius: 12px;
    margin-bottom: 1.5rem;
    border: 1px solid var(--border-color);
    overflow: hidden;
    box-shadow: var(--shadow);
}

.card-header {
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
    background: rgba(99, 102, 241, 0.05);
    border-left: 4px solid var(--primary-color);
}

.card-header h3 {
    margin: 0;
    color: var(--text-color);
    font-size: 1.1rem;
    font-weight: 600;
}

.card-content {
    padding: 2rem;
}

/* Form Improvements */
.toggle-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.toggle-group.full-width {
    grid-column: 1 / -1;
}

.input-with-info {
    position: relative;
}

.input-info {
    font-size: 0.75rem;
    color: var(--text-light);
    margin-top: 0.5rem;
}

.input-with-suffix {
    position: relative;
    display: flex;
    align-items: center;
}

.input-suffix {
    position: absolute;
    right: 1rem;
    color: var(--text-light);
    font-weight: 500;
}

/* Save Section */
.save-section {
    text-align: center;
    margin-top: 3rem;
    padding-top: 2rem;
    border-top: 2px solid var(--border-color);
}

/* Login Section */
.login-section, .file-section {
    text-align: center;
}

.login-section h1, .file-section h1 {
    color: var(--text-color);
    margin-bottom: 2rem;
    font-size: 2rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    text-shadow: var(--shadow);
}

/* Site Tabs */
.site-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2.5rem;
    padding: 0.5rem;
    background: var(--light-color);
    border-radius: 16px;
    border: 1px solid var(--border-color);
    position: relative;
    box-shadow: var(--shadow-lg);
}

.site-tab {
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
    color: var(--text-color);
    flex: 1;
    text-align: center;
    position: relative;
    z-index: 2;
}

.site-tab.active {
    color: white;
    box-shadow: var(--shadow-lg);
}

.tab-highlight {
    position: absolute;
    top: 0.5rem;
    left: 0.5rem;
    height: calc(100% - 1rem);
    width: calc(33.333% - 1rem);
    background: var(--gradient-primary);
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    z-index: 1;
    box-shadow: var(--shadow-lg);
}

.site-tab:hover:not(.active) {
    background: rgba(99, 102, 241, 0.1);
}

/* Form Styles */
.form-group {
    margin-bottom: 1.75rem;
    text-align: left;
}

label {
    display: block;
    margin-bottom: 0.75rem;
    color: var(--text-color);
    font-weight: 600;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

input[type="text"],
input[type="password"],
input[type="file"],
input[type="number"],
input[type="email"],
input[type="tel"],
textarea {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 2px solid var(--border-color);
    border-radius: 12px;
    font-size: 0.875rem;
    transition: all 0.3s ease;
    background: var(--input-bg);
    color: var(--text-color);
    font-family: inherit;
    box-shadow: var(--shadow);
}

input[type="text"]:focus,
input[type="password"]:focus,
input[type="number"]:focus,
input[type="email"]:focus,
input[type="tel"]:focus,
textarea:focus {
    border-color: var(--primary-color);
    outline: none;
    box-shadow: 0 0 0 4px rgba(99, 102, 241, 0.1), var(--shadow-lg);
    transform: translateY(-2px);
}

textarea {
    min-height: 120px;
    resize: vertical;
    line-height: 1.5;
}

/* Button Styles */
.btn {
    background: var(--gradient-primary);
    color: white;
    border: none;
    padding: 1rem 2rem;
    border-radius: 12px;
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 600;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 0.75rem;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-lg);
}

.btn:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-2xl);
}

.btn:active {
    transform: translateY(-1px);
}

.btn:disabled {
    background: var(--text-light);
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.btn-secondary {
    background: var(--gradient-secondary);
}

.btn-success {
    background: linear-gradient(135deg, var(--success-color), #059669);
}

.btn-warning {
    background: linear-gradient(135deg, var(--warning-color), #d97706);
}

.btn-danger {
    background: linear-gradient(135deg, var(--danger-color), #dc2626);
}

.btn-tertiary {
    background: linear-gradient(135deg, var(--info-color), #0891b2);
}

.back-btn {
    background: var(--secondary-color);
    margin-right: 15px;
}

.back-btn:hover {
    background: var(--secondary-hover);
}

/* File Info */
.file-info {
    background: var(--light-color);
    padding: 2rem;
    border-radius: 16px;
    margin: 2rem 0;
    border: 1px solid var(--border-color);
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.file-info::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-primary);
}

.file-info p {
    margin: 0.75rem 0;
    color: var(--text-color);
    font-size: 0.875rem;
}

.file-name {
    font-weight: 700;
    color: var(--text-color);
    margin-bottom: 0.75rem;
    font-size: 1.125rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.folder-info {
    color: var(--text-light);
    font-size: 0.75rem;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

/* Status Messages */
.status {
    padding: 1.25rem;
    border-radius: 12px;
    margin: 1.5rem 0;
    font-weight: 600;
    border: 2px solid;
    font-size: 0.875rem;
    position: relative;
    padding-left: 3.5rem;
    box-shadow: var(--shadow);
}

.status::before {
    content: '';
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    background-size: contain;
    background-repeat: no-repeat;
}

.status.success {
    background: rgba(16, 185, 129, 0.1);
    color: #065f46;
    border-color: #10b981;
}

.status.success::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%2310b981' viewBox='0 0 24 24'%3E%3Cpath d='M9 16.17L4.83 12l-1.42 1.41L9 19 21 7l-1.41-1.41z'/%3E%3C/svg%3E");
}

.dark-theme .status.success {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
}

.status.error {
    background: rgba(239, 68, 68, 0.1);
    color: #991b1b;
    border-color: #ef4444;
}

.status.error::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%23ef4444' viewBox='0 0 24 24'%3E%3Cpath d='M19 6.41L17.59 5 12 10.59 6.41 5 5 6.41 10.59 12 5 17.59 6.41 19 12 13.41 17.59 19 19 17.59 13.41 12z'/%3E%3C/svg%3E");
}

.dark-theme .status.error {
    background: rgba(239, 68, 68, 0.2);
    color: #ef4444;
}

.status.info {
    background: rgba(37, 99, 235, 0.1);
    color: #1e40af;
    border-color: #3b82f6;
}

.status.info::before {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='%233b82f6' viewBox='0 0 24 24'%3E%3Cpath d='M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm1 15h-2v-6h2v6zm0-8h-2V7h2v2z'/%3E%3C/svg%3E");
}

.dark-theme .status.info {
    background: rgba(37, 99, 235, 0.2);
    color: #3b82f6;
}

.status.loading {
    background: rgba(107, 114, 128, 0.1);
    color: var(--text-light);
    border-color: var(--text-light);
}

/* Utility Classes */
.hidden {
    display: none !important;
}

.loading {
    color: var(--text-light);
    font-style: italic;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.loading::after {
    content: '';
    width: 1rem;
    height: 1rem;
    border: 2px solid var(--border-color);
    border-top: 2px solid var(--primary-color);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

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

/* File Upload */
.file-upload {
    border: 2px dashed var(--border-color);
    padding: 3rem 2rem;
    border-radius: 16px;
    margin: 1.5rem 0;
    transition: all 0.3s ease;
    text-align: center;
    background: var(--light-color);
    position: relative;
    box-shadow: var(--shadow);
}

.file-upload.dragover {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.05);
    transform: scale(1.02);
    box-shadow: var(--shadow-lg);
}

.file-upload p {
    margin: 0.75rem 0;
    color: var(--text-color);
    font-size: 0.875rem;
}

.upload-notice {
    background: rgba(245, 158, 11, 0.1);
    border: 2px solid var(--warning-color);
    color: #92400e;
    padding: 1.25rem;
    border-radius: 12px;
    margin: 1.5rem 0;
    font-size: 0.75rem;
    font-weight: 500;
    box-shadow: var(--shadow);
}

.dark-theme .upload-notice {
    background: rgba(245, 158, 11, 0.2);
    color: #f59e0b;
}

/* Button Groups */
.button-group {
    display: flex;
    gap: 1rem;
    flex-wrap: wrap;
    margin: 2rem 0;
    justify-content: center;
}

/* Site Content */
.site-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.site-content.active {
    display: block;
}

/* File URL */
.file-url {
    background: var(--light-color);
    padding: 1rem 1.25rem;
    border-radius: 10px;
    margin: 1.5rem 0;
    word-break: break-all;
    font-size: 0.75rem;
    border: 2px dashed var(--border-color);
    color: var(--text-color);
    font-family: 'Monaco', 'Consolas', monospace;
    position: relative;
    padding-left: 3rem;
    box-shadow: var(--shadow);
}

.file-url::before {
    content: '🔗';
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
}

/* Toggle Switch */
.toggle-group {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
    padding: 10px;
    background: var(--bg-color);
    border-radius: 8px;
}

.toggle-label {
    flex: 1;
    font-weight: 500;
    color: var(--text-color);
}

.toggle-switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

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

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

.toggle-slider:before {
    position: absolute;
    content: "";
    height: 16px;
    width: 16px;
    left: 4px;
    bottom: 4px;
    background-color: white;
    transition: .4s;
    border-radius: 50%;
}

input:checked + .toggle-slider {
    background-color: var(--primary-color);
}

input:checked + .toggle-slider:before {
    transform: translateX(26px);
}

/* Number Input Group */
.number-input-group {
    display: flex;
    align-items: center;
    gap: 10px;
}

.number-input {
    width: 80px;
    text-align: center;
}

.number-btn {
    width: 35px;
    height: 35px;
    border: 2px solid var(--border-color);
    background: var(--bg-color);
    border-radius: 6px;
    cursor: pointer;
    font-size: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.number-btn:hover {
    background: var(--primary-color);
    color: white;
}

/* Form Grid */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

/* Contact Block */
.contact-block {
    background: var(--bg-color);
    padding: 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid var(--primary-color);
}

.contact-block h3 {
    color: var(--primary-color);
    margin-bottom: 15px;
}

/* Уведомления */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 10px;
    color: white;
    font-weight: 600;
    z-index: 10000;
    box-shadow: 0 10px 25px rgba(0,0,0,0.2);
    transform: translateX(400px);
    opacity: 0;
    transition: all 0.3s ease;
    max-width: 300px;
}

.notification.show {
    transform: translateX(0);
    opacity: 1;
}

.notification.success {
    background: linear-gradient(135deg, #10b981, #059669);
}

.notification.error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
}

.notification.info {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
}

/* Поля времени */
.time-input-group {
    display: flex;
    gap: 15px;
    align-items: center;
}

.time-field {
    flex: 1;
}

.time-label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--text-color);
}

.time-input {
    width: 100%;
    padding: 10px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    background: var(--input-bg);
    color: var(--text-color);
    font-size: 14px;
}

.time-input:focus {
    border-color: var(--primary-color);
    outline: none;
}

.time-separator {
    font-size: 18px;
    font-weight: bold;
    color: var(--text-light);
    margin-top: 25px;
}

/* Текст помощи */
.help-text {
    background: rgba(99, 102, 241, 0.1);
    border: 1px solid rgba(99, 102, 241, 0.3);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 15px;
    font-size: 13px;
    line-height: 1.5;
    color: var(--text-color);
}

.dark-theme .help-text {
    background: rgba(99, 102, 241, 0.2);
    border-color: rgba(99, 102, 241, 0.4);
}

/* Стили для страницы описаний (как в оригинале) */
.descriptions-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1.5rem;
    border-bottom: 2px solid var(--border-color);
}

.descriptions-header h2 {
    color: var(--text-color);
    font-size: 1.5rem;
    font-weight: 700;
    text-shadow: var(--shadow);
}

.description-count {
    font-size: 0.875rem;
    color: var(--text-light);
    font-weight: 600;
    background: var(--light-color);
    padding: 0.5rem 1rem;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow);
}

/* Description Items */
.description-item {
    background: var(--light-color);
    border: 1px solid var(--border-color);
    border-radius: 16px;
    padding: 2rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: var(--shadow-xl);
}

.description-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 4px;
    height: 100%;
    background: var(--gradient-primary);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.description-item:hover::before {
    opacity: 1;
}

.description-item:hover {
    box-shadow: var(--shadow-2xl);
    border-color: var(--primary-color);
    transform: translateY(-2px);
}

.description-content {
    color: var(--text-color);
    line-height: 1.7;
    margin-bottom: 1.5rem;
    white-space: pre-wrap;
    font-size: 0.875rem;
}

.description-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
    flex-wrap: wrap;
}

.no-descriptions {
    text-align: center;
    padding: 4rem 2rem;
    color: var(--text-light);
    font-style: italic;
    font-size: 0.875rem;
    background: var(--light-color);
    border-radius: 16px;
    border: 2px dashed var(--border-color);
    box-shadow: var(--shadow);
}

/* Modal Styles */
.modal {
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    animation: modalFadeIn 0.3s ease;
}

@keyframes modalFadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background-color: var(--bg-color);
    border-radius: 20px;
    width: 100%;
    max-width: 500px;
    box-shadow: var(--shadow-2xl);
    border: 1px solid var(--border-color);
    animation: modalSlideIn 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    position: relative;
    overflow: hidden;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(-20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: var(--gradient-primary);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1.5rem 2rem;
    border-bottom: 1px solid var(--border-color);
}

.modal-header h3 {
    margin: 0;
    font-size: 1.25rem;
    color: var(--text-color);
    font-weight: 700;
}

.close {
    color: var(--text-light);
    font-size: 1.5rem;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    width: 2.5rem;
    height: 2.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 10px;
}

.close:hover {
    background: var(--light-color);
    color: var(--text-color);
    transform: rotate(90deg);
}

.modal-body {
    padding: 2rem;
}

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

/* Кнопка возврата наверх */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 3.5rem;
    height: 3.5rem;
    background: var(--gradient-primary);
    color: white;
    border: none;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    box-shadow: var(--shadow-2xl);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(20px);
    z-index: 999;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.back-to-top:hover {
    transform: translateY(-5px) scale(1.1);
    box-shadow: var(--shadow-2xl);
}

/* Description Header */
.description-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
    padding-bottom: 10px;
    border-bottom: 2px solid var(--border-color);
}

.description-number {
    font-weight: 700;
    font-size: 18px;
    color: #fff;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    padding: 6px 12px;
    border-radius: 6px;
    min-width: 40px;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.description-id {
    font-size: 13px;
    color: var(--text-light);
    background: var(--light-color);
    padding: 4px 8px;
    border-radius: 4px;
    border: 1px dashed var(--border-color);
    font-family: 'Courier New', monospace;
}

/* Для темной темы */
.dark-theme .description-number {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    color: #1a1a1a;
}

.dark-theme .description-id {
    color: #adb5bd;
    background: #343a40;
    border-color: #495057;
}

.dark-theme .description-header {
    border-bottom-color: #495057;
}


/* Стили для модального окна водяных знаков */
.watermark-info {
    margin-bottom: 20px;
    padding: 15px;
    background-color: var(--bg-secondary);
    border-radius: 8px;
}

.watermark-info p {
    margin: 0 0 10px 0;
    color: var(--text-secondary);
    font-size: 0.9em;
}

.watermark-count {
    font-weight: 600;
    color: var(--primary-color);
}

.watermark-list-container {
    max-height: 300px;
    overflow-y: auto;
    margin-bottom: 20px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 10px;
    background-color: var(--bg-secondary);
}

.watermark-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px;
    margin-bottom: 8px;
    background-color: var(--bg-primary);
    border: 1px solid var(--border-color);
    border-radius: 6px;
}

.watermark-item:last-child {
    margin-bottom: 0;
}

.watermark-content {
    flex-grow: 1;
    padding-right: 10px;
    font-size: 0.95em;
}

.watermark-actions {
    display: flex;
    gap: 5px;
}

.btn-sm {
    padding: 4px 8px;
    font-size: 0.85em;
}

.no-watermarks {
    text-align: center;
    padding: 20px;
    color: var(--text-secondary);
    font-style: italic;
}

.watermark-form {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
}

.watermark-form h4 {
    margin: 0 0 10px 0;
    color: var(--text-primary);
}

.watermark-input {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-size: 1em;
    background-color: var(--bg-primary);
    color: var(--text-primary);
    transition: border-color 0.2s;
}

.watermark-input:focus {
    outline: none;
    border-color: var(--primary-color);
}

/* Responsive Design */
@media (max-width: 768px) {
    .container {
        margin: 1rem;
        padding: 1.5rem;
        border-radius: 16px;
    }
    
    .header-content {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
        padding: 0 1rem;
    }
    
    .header-actions {
        width: 100%;
        justify-content: center;
        flex-direction: column;
    }
    
    .user-info-header {
        order: -1;
        width: 100%;
        justify-content: center;
    }
    
    .dashboard-nav {
        flex-direction: column;
    }
    
    .settings-nav {
        flex-direction: column;
    }
    
    .site-tabs {
        flex-direction: column;
    }
    
    .button-group {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
        justify-content: center;
    }
    
    .form-grid {
        grid-template-columns: 1fr;
    }
    
    .toggle-grid {
        grid-template-columns: 1fr;
    }
    
    .nav-item {
        padding: 1rem;
    }
    
    .dashboard-card {
        padding: 1.5rem;
    }
    
    .settings-content {
        padding: 1rem;
    }
    
    .card-content {
        padding: 1.5rem;
    }
    
    .number-input-group {
        justify-content: center;
    }
    
    .descriptions-header {
        flex-direction: column;
        gap: 1rem;
        text-align: center;
    }
    
    .description-actions {
        flex-direction: column;
    }
    
    .modal-content {
        margin: 1rem;
    }
    
    .modal-footer {
        flex-direction: column;
    }
    
    .back-to-top {
        bottom: 1rem;
        right: 1rem;
        width: 3rem;
        height: 3rem;
        font-size: 1.25rem;
    }
}

/* Enhanced scrollbar */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--light-color);
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-dark);
}