* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

:root {
    --primary: #4361ee;
    --secondary: #3f37c9;
    --success: #4cc9f0;
    --danger: #f72585;
    --warning: #f8961e;
    --light: #f8f9fa;
    --dark: #212529;
    --gray: #6c757d;
    --shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

body {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: var(--dark);
    line-height: 1.6;
    min-height: 100vh;
    padding-bottom: 2rem;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

/* Header */
header {
    background-color: rgba(255, 255, 255, 0.95);
    padding: 1.5rem 0;
    box-shadow: var(--shadow);
    margin-bottom: 2rem;
    border-radius: 0 0 15px 15px;
}

.header-content {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

h1 {
    font-size: clamp(1.8rem, 4vw, 2.5rem);
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    margin-bottom: 0.5rem;
}

.subtitle {
    color: var(--gray);
    font-size: clamp(0.9rem, 2vw, 1.1rem);
}

/* Cards */
.card {
    background: white;
    border-radius: 15px;
    box-shadow: var(--shadow);
    padding: 1.5rem;
    margin-bottom: 2rem;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.card-title {
    font-size: 1.5rem;
    margin-bottom: 1.5rem;
    color: var(--primary);
    display: flex;
    align-items: center;
    gap: 10px;
}

/* Upload Area */
.upload-area {
    border: 2px dashed #dee2e6;
    border-radius: 10px;
    padding: 2rem 1rem;
    text-align: center;
    transition: all 0.3s ease;
    cursor: pointer;
    margin-bottom: 1.5rem;
}

.upload-area:hover, .upload-area.dragover {
    border-color: var(--primary);
    background-color: rgba(67, 97, 238, 0.05);
}

.upload-icon {
    font-size: 2.5rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.upload-text {
    margin-bottom: 1rem;
    font-size: 1.1rem;
}

/* Forms */
.form-group {
    margin-bottom: 1.5rem;
}

label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

input, select, textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s ease;
}

input:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(67, 97, 238, 0.1);
}

/* Buttons */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 50px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    box-shadow: 0 4px 6px rgba(67, 97, 238, 0.3);
    text-align: center;
    min-height: 44px;
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 12px rgba(67, 97, 238, 0.4);
}

.btn-outline {
    background: transparent;
    border: 2px solid var(--primary);
    color: var(--primary);
    box-shadow: none;
}

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

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

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

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

.btn-info {
    background: linear-gradient(135deg, #3a86ff, #8338ec);
}

.btn-sm {
    padding: 8px 15px;
    font-size: 0.9rem;
    min-height: 36px;
}

.file-input {
    display: none;
}

/* Sites Grid */
.sites-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

.site-card {
    background: white;
    border-radius: 15px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.site-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.15);
}

.site-preview {
    height: 140px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2.5rem;
    position: relative;
}

.site-type {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 4px 8px;
    border-radius: 20px;
    font-size: 0.7rem;
}

.html-site {
    background: linear-gradient(135deg, #667eea, #764ba2);
}

.multi-site {
    background: linear-gradient(135deg, #f093fb, #f5576c);
}

.single-site {
    background: linear-gradient(135deg, #4facfe, #00f2fe);
}

.site-info {
    padding: 1.5rem;
}

.site-name {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark);
}

.site-meta {
    color: var(--gray);
    font-size: 0.9rem;
    margin-bottom: 1.5rem;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.site-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.site-actions .btn {
    flex: 1;
    min-width: 80px;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 2rem;
    color: var(--gray);
}

.empty-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    color: #dee2e6;
}

/* Instructions */
.instructions {
    background: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    color: white;
    border-radius: 15px;
    padding: 1.5rem;
    margin-bottom: 2rem;
}

.instructions h3 {
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.instructions ol {
    margin-left: 1.5rem;
    margin-bottom: 1.5rem;
}

.instructions li {
    margin-bottom: 0.5rem;
}

.file-types {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1.5rem;
}

.file-type-card {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    padding: 1rem;
    text-align: center;
}

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

/* Alerts */
.password-required {
    background-color: rgba(247, 37, 133, 0.1);
    border-left: 4px solid var(--danger);
    padding: 1rem;
    margin-bottom: 1rem;
    border-radius: 0 8px 8px 0;
}

.domain-info {
    background: rgba(67, 97, 238, 0.1);
    border-radius: 8px;
    padding: 10px;
    margin: 10px 0;
    font-size: 0.9rem;
    text-align: center;
}

.url-display {
    background-color: #f8f9fa;
    border-radius: 8px;
    padding: 12px;
    margin: 15px 0;
    word-break: break-all;
    font-family: monospace;
    border: 1px solid #e9ecef;
    font-size: 0.9rem;
}

/* File Info */
#fileInfo {
    display: none;
    margin-bottom: 1.5rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 10px;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

#removeFile {
    background: none;
    border: none;
    color: var(--danger);
    cursor: pointer;
    padding: 5px;
}

/* Password Input */
.password-input-group {
    margin-bottom: 1.5rem;
}

.password-input-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.password-note {
    font-size: 0.9rem;
    color: var(--gray);
    margin-top: 0.5rem;
}

/* Footer */
footer {
    text-align: center;
    margin-top: 3rem;
    color: rgba(255, 255, 255, 0.7);
    padding: 1rem 0;
}

/* Modals */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    padding: 15px;
    box-sizing: border-box;
}

.modal-content {
    background-color: white;
    border-radius: 15px;
    padding: 1.5rem;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    position: relative;
    animation: modalFadeIn 0.3s ease;
}

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

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

.modal-title {
    font-size: 1.5rem;
    color: var(--primary);
    margin: 0;
}

.close-btn {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray);
    padding: 5px;
    min-height: auto;
}

.modal-body {
    margin-bottom: 1.5rem;
}

.modal-footer {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    flex-wrap: wrap;
}

.modal-footer .btn {
    flex: 1;
    min-width: 120px;
}

.delete-modal .modal-content {
    max-width: 400px;
}

/* Mobile Responsive */
@media (max-width: 768px) {
    .container {
        padding: 0 10px;
    }
    
    .header-content {
        flex-direction: column;
        text-align: center;
    }
    
    .card {
        padding: 1rem;
        margin-bottom: 1.5rem;
    }
    
    .upload-area {
        padding: 1.5rem 1rem;
    }
    
    .upload-icon {
        font-size: 2rem;
    }
    
    .sites-grid {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    
    .site-actions {
        flex-direction: column;
    }
    
    .file-types {
        grid-template-columns: 1fr;
    }
    
    .modal-content {
        padding: 1rem;
        margin: 10px;
    }
    
    .modal-footer {
        flex-direction: column;
    }
    
    .btn {
        width: 100%;
    }
    
    .site-meta {
        flex-direction: column;
        gap: 0.3rem;
    }
}

@media (max-width: 480px) {
    .site-preview {
        height: 120px;
        font-size: 2rem;
    }
    
    .site-info {
        padding: 1rem;
    }
    
    .instructions {
        padding: 1rem;
    }
    
    .instructions ol {
        margin-left: 1rem;
    }
    
    .upload-text {
        font-size: 1rem;
    }
}