/* ============================================
   RESET & BASE STYLES
   ============================================ */

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

:root {
    /* Color Palette */
    --gradient-primary: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    --gradient-secondary: linear-gradient(135deg, #f093fb 0%, #f5576c 100%);
    --gradient-accent: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
    --gradient-success: linear-gradient(135deg, #11998e 0%, #38ef7d 100%);

    /* Background Colors */
    --bg-dark: #0f0f23;
    --bg-darker: #080815;
    --bg-glass: rgba(255, 255, 255, 0.05);
    --bg-glass-hover: rgba(255, 255, 255, 0.1);

    /* Text Colors */
    --text-primary: #ffffff;
    --text-secondary: rgba(255, 255, 255, 0.7);
    --text-muted: rgba(255, 255, 255, 0.5);

    /* Border & Effects */
    --border-glass: rgba(255, 255, 255, 0.1);
    --shadow-glass: 0 8px 32px 0 rgba(0, 0, 0, 0.37);
    --glow-primary: 0 0 20px rgba(102, 126, 234, 0.5);
    --glow-accent: 0 0 20px rgba(79, 172, 254, 0.5);

    /* Spacing */
    --spacing-xs: 0.5rem;
    --spacing-sm: 1rem;
    --spacing-md: 1.5rem;
    --spacing-lg: 2rem;
    --spacing-xl: 3rem;

    /* Typography */
    --font-heading: 'Kanit', sans-serif;
    --font-body: 'Inter', sans-serif;
}

body {
    font-family: var(--font-body);
    background: var(--bg-dark);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

/* ============================================
   ANIMATED BACKGROUND
   ============================================ */

.animated-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: -1;
    overflow: hidden;
}

.gradient-bg {
    position: absolute;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        45deg,
        #0f0f23 0%,
        #1a0b2e 25%,
        #16213e 50%,
        #0f0f23 75%,
        #1a0b2e 100%
    );
    background-size: 400% 400%;
    animation: gradientShift 15s ease infinite;
}

.particles-container {
    position: absolute;
    width: 100%;
    height: 100%;
    pointer-events: none;
}

/* ============================================
   MODAL OVERLAY
   ============================================ */

.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    animation: fadeIn 0.3s ease;
}

/* ============================================
   LOGIN MODAL
   ============================================ */

.login-modal {
    width: 100%;
    max-width: 450px;
    padding: var(--spacing-md);
    animation: slideUp 0.5s ease;
}

.login-card {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 24px;
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-glass);
    position: relative;
    overflow: hidden;
}

.login-card::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: var(--gradient-primary);
    border-radius: 24px;
    opacity: 0.3;
    z-index: -1;
    filter: blur(10px);
}

.login-header {
    text-align: center;
    margin-bottom: var(--spacing-lg);
}

.logo-container {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--spacing-md);
    background: var(--gradient-primary);
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--glow-primary);
    animation: float 3s ease-in-out infinite;
}

.logo-icon {
    width: 40px;
    height: 40px;
    color: white;
}

.login-title {
    font-family: var(--font-heading);
    font-size: 2rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--spacing-xs);
}

.login-subtitle {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ============================================
   FORM INPUTS
   ============================================ */

.login-form,
.generate-form {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-md);
}

.input-group {
    position: relative;
}

.input-group input {
    width: 100%;
    padding: 1rem 1rem 1rem 3rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid var(--border-glass);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: var(--font-body);
    transition: all 0.3s ease;
    outline: none;
}

.input-group input:focus {
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.input-group input:focus + label {
    color: #667eea;
    transform: translateY(-28px) scale(0.85);
}

.input-group input:not(:placeholder-shown) + label {
    transform: translateY(-28px) scale(0.85);
}

.input-group label {
    position: absolute;
    left: 3rem;
    top: 1rem;
    color: var(--text-muted);
    font-size: 1rem;
    pointer-events: none;
    transition: all 0.3s ease;
    transform-origin: left;
}

.input-icon {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 20px;
    color: var(--text-muted);
    pointer-events: none;
    z-index: 1;
}

.toggle-password {
    position: absolute;
    right: 1rem;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    padding: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.3s ease;
}

.toggle-password:hover {
    color: var(--text-primary);
}

.toggle-password svg {
    width: 20px;
    height: 20px;
}

/* ============================================
   BUTTONS
   ============================================ */

.login-button,
.submit-button {
    width: 100%;
    padding: 1rem 2rem;
    background: var(--gradient-primary);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    font-family: var(--font-heading);
    cursor: pointer;
    position: relative;
    overflow: hidden;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.login-button:hover,
.submit-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.login-button:active,
.submit-button:active {
    transform: translateY(0);
}

.login-button.loading,
.submit-button.loading {
    pointer-events: none;
}

.button-text {
    transition: opacity 0.3s ease;
}

.login-button.loading .button-text,
.submit-button.loading .button-text {
    opacity: 0;
}

.button-loader {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 24px;
    height: 24px;
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top-color: white;
    border-radius: 50%;
    opacity: 0;
    animation: spin 0.8s linear infinite;
}

.login-button.loading .button-loader,
.submit-button.loading .button-loader {
    opacity: 1;
}

/* ============================================
   ERROR MESSAGE
   ============================================ */

.error-message {
    background: rgba(245, 87, 108, 0.1);
    border: 1px solid rgba(245, 87, 108, 0.3);
    border-radius: 8px;
    padding: 0.75rem 1rem;
    color: #f5576c;
    font-size: 0.9rem;
    display: none;
    animation: shake 0.5s ease;
}

.error-message.show {
    display: block;
}

/* ============================================
   MAIN APPLICATION
   ============================================ */

.main-app {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

/* Header */
.app-header {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border-bottom: 1px solid var(--border-glass);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.brand {
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
}

.brand-icon {
    width: 32px;
    height: 32px;
    color: #667eea;
}

.brand-name {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.user-section {
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.username-display {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.logout-button {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.6rem 1.2rem;
    background: rgba(245, 87, 108, 0.1);
    border: 1px solid rgba(245, 87, 108, 0.3);
    border-radius: 8px;
    color: #f5576c;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.logout-button:hover {
    background: rgba(245, 87, 108, 0.2);
    transform: translateY(-1px);
}

.logout-button svg {
    width: 18px;
    height: 18px;
}

/* Main Content */
.main-content {
    flex: 1;
    padding: var(--spacing-xl) 0;
}

.container {
    max-width: 900px;
    margin: 0 auto;
    padding: 0 var(--spacing-md);
}

.page-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
}

.page-title {
    font-family: var(--font-heading);
    font-size: 2.5rem;
    font-weight: 800;
    background: var(--gradient-primary);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin-bottom: var(--spacing-sm);
}

.page-subtitle {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Form Container */
.form-container {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 24px;
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-glass);
}

.form-group {
    margin-bottom: var(--spacing-lg);
}

.form-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: var(--spacing-sm);
    color: var(--text-primary);
    font-weight: 500;
    font-size: 1rem;
}

.form-label svg {
    width: 20px;
    height: 20px;
    color: #667eea;
}

.required {
    color: #f5576c;
}

.form-input,
.form-textarea {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid var(--border-glass);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: var(--font-body);
    transition: all 0.3s ease;
    outline: none;
}

.form-input:focus,
.form-textarea:focus {
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.form-textarea {
    resize: vertical;
    min-height: 100px;
}

/* Select Dropdown */
.form-select {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid var(--border-glass);
    border-radius: 12px;
    color: var(--text-primary);
    font-size: 1rem;
    font-family: var(--font-body);
    transition: all 0.3s ease;
    outline: none;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='24' height='24' viewBox='0 0 24 24' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1.2rem;
    padding-right: 3rem;
}

.form-select:hover {
    border-color: rgba(102, 126, 234, 0.5);
    background: rgba(255, 255, 255, 0.08);
}

.form-select:focus {
    border-color: #667eea;
    background: rgba(255, 255, 255, 0.08);
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.form-select option {
    background: #1a1a2e;
    color: var(--text-primary);
    padding: 0.5rem;
}

/* Model Info */
.model-info {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-top: 0.75rem;
    padding: 0.75rem 1rem;
    background: rgba(102, 126, 234, 0.1);
    border-left: 3px solid #667eea;
    border-radius: 8px;
    font-size: 0.875rem;
    color: var(--text-secondary);
    line-height: 1.5;
}

.model-info i {
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    color: #667eea;
}

/* Slider */
.slider-container {
    position: relative;
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.form-slider {
    flex: 1;
    -webkit-appearance: none;
    appearance: none;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    outline: none;
}

.form-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    background: var(--gradient-primary);
    border-radius: 50%;
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.form-slider::-webkit-slider-thumb:hover {
    transform: scale(1.2);
}

.form-slider::-moz-range-thumb {
    width: 24px;
    height: 24px;
    background: var(--gradient-primary);
    border-radius: 50%;
    cursor: pointer;
    border: none;
    box-shadow: 0 2px 8px rgba(102, 126, 234, 0.4);
    transition: all 0.3s ease;
}

.slider-value {
    min-width: 40px;
    padding: 0.5rem 1rem;
    background: var(--gradient-primary);
    border-radius: 8px;
    color: white;
    font-weight: 600;
    text-align: center;
}

/* Image URLs */
.image-urls-container {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.image-url-item {
    display: flex;
    gap: var(--spacing-sm);
    align-items: flex-start;
    animation: slideIn 0.3s ease;
}

.image-url-item input {
    flex: 1;
}

.remove-url-button {
    width: 48px;
    height: 48px;
    background: rgba(245, 87, 108, 0.1);
    border: 1px solid rgba(245, 87, 108, 0.3);
    border-radius: 8px;
    color: #f5576c;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    flex-shrink: 0;
}

.remove-url-button:hover {
    background: rgba(245, 87, 108, 0.2);
    transform: scale(1.05);
}

.remove-url-button svg {
    width: 20px;
    height: 20px;
}

.add-url-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    width: 100%;
    padding: 1rem;
    background: rgba(79, 172, 254, 0.1);
    border: 2px dashed rgba(79, 172, 254, 0.3);
    border-radius: 12px;
    color: #4facfe;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.add-url-button:hover {
    background: rgba(79, 172, 254, 0.2);
    border-color: #4facfe;
    transform: translateY(-2px);
}

.add-url-button svg {
    width: 20px;
    height: 20px;
}

/* Image Input Tabs */
.image-input-tabs {
    display: flex;
    gap: var(--spacing-sm);
    margin-bottom: var(--spacing-md);
}

.tab-button {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    padding: 0.875rem 1.5rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.6);
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.tab-button:hover {
    background: rgba(255, 255, 255, 0.08);
    border-color: rgba(255, 255, 255, 0.2);
}

.tab-button.active {
    background: var(--gradient-primary);
    border-color: transparent;
    color: white;
}

.tab-button svg {
    width: 18px;
    height: 18px;
}

.image-input-content {
    display: none;
}

.image-input-content.active {
    display: block;
}

/* Upload Area */
.upload-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 3rem 2rem;
    background: rgba(79, 172, 254, 0.05);
    border: 2px dashed rgba(79, 172, 254, 0.3);
    border-radius: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-align: center;
}

.upload-area:hover {
    background: rgba(79, 172, 254, 0.1);
    border-color: #4facfe;
}

.upload-area.drag-over {
    background: rgba(79, 172, 254, 0.15);
    border-color: #4facfe;
    transform: scale(1.02);
}

.upload-area svg {
    width: 48px;
    height: 48px;
    color: #4facfe;
    margin-bottom: 1rem;
}

.upload-area p {
    margin: 0;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 500;
}

.upload-hint {
    margin-top: 0.5rem;
    font-size: 0.875rem;
    color: rgba(255, 255, 255, 0.5);
}

/* Uploaded Images Preview */
.uploaded-images-preview {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: var(--spacing-md);
    margin-top: var(--spacing-md);
}

.uploaded-image-item {
    position: relative;
    aspect-ratio: 1;
    border-radius: 12px;
    overflow: hidden;
    border: 2px solid var(--border-glass);
    background: rgba(255, 255, 255, 0.05);
}

.uploaded-image-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.remove-uploaded-image {
    position: absolute;
    top: 0.5rem;
    right: 0.5rem;
    width: 28px;
    height: 28px;
    background: rgba(245, 87, 108, 0.9);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    opacity: 0;
}

.uploaded-image-item:hover .remove-uploaded-image {
    opacity: 1;
}

.remove-uploaded-image:hover {
    background: #f5576c;
    transform: scale(1.1);
}

.remove-uploaded-image svg {
    width: 16px;
    height: 16px;
}

/* Image Preview */
.image-preview {
    width: 48px;
    height: 48px;
    border-radius: 8px;
    object-fit: cover;
    border: 2px solid var(--border-glass);
    flex-shrink: 0;
}

/* Aspect Ratio Grid */
.aspect-ratio-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: var(--spacing-sm);
}

.aspect-ratio-card {
    position: relative;
    cursor: pointer;
}

.aspect-ratio-card input {
    position: absolute;
    opacity: 0;
    pointer-events: none;
}

.ratio-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 2px solid var(--border-glass);
    border-radius: 12px;
    transition: all 0.3s ease;
}

.aspect-ratio-card input:checked + .ratio-content {
    background: rgba(102, 126, 234, 0.2);
    border-color: #667eea;
    box-shadow: 0 0 0 4px rgba(102, 126, 234, 0.1);
}

.ratio-content:hover {
    background: rgba(255, 255, 255, 0.08);
    transform: translateY(-2px);
}

.ratio-preview {
    width: 60px;
    height: 40px;
    background: var(--gradient-accent);
    border-radius: 6px;
    position: relative;
}

.ratio-preview.square {
    width: 40px;
    height: 40px;
}

.ratio-preview.portrait {
    width: 30px;
    height: 50px;
}

.ratio-preview.vertical {
    width: 35px;
    height: 45px;
}

.ratio-preview.standard {
    width: 50px;
    height: 40px;
}

.ratio-label {
    font-weight: 600;
    color: var(--text-primary);
}

.ratio-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

/* Submit Button */
.submit-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-top: var(--spacing-md);
    font-size: 1.2rem;
}

.submit-button svg {
    width: 24px;
    height: 24px;
}

/* ============================================
   LOADING MODAL
   ============================================ */

.loading-modal {
    width: 100%;
    max-width: 400px;
    padding: var(--spacing-md);
}

.loading-card {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 24px;
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-glass);
    text-align: center;
}

.loading-spinner {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--spacing-md);
}

.spinner {
    width: 100%;
    height: 100%;
    border: 4px solid rgba(255, 255, 255, 0.1);
    border-top-color: #667eea;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

.loading-title {
    font-family: var(--font-heading);
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
}

.loading-subtitle {
    color: var(--text-secondary);
    margin-bottom: var(--spacing-md);
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background: var(--gradient-primary);
    border-radius: 4px;
    animation: progress 2s ease-in-out infinite;
}

/* ============================================
   SUCCESS MODAL
   ============================================ */

.success-modal {
    width: 100%;
    max-width: 450px;
    padding: var(--spacing-md);
}

.success-card {
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 24px;
    padding: var(--spacing-xl);
    box-shadow: var(--shadow-glass);
    text-align: center;
}

.success-icon {
    width: 80px;
    height: 80px;
    margin: 0 auto var(--spacing-md);
    background: var(--gradient-success);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: scaleIn 0.5s ease;
}

.success-icon svg {
    width: 48px;
    height: 48px;
    color: white;
}

.success-title {
    font-family: var(--font-heading);
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: var(--spacing-sm);
}

.success-subtitle {
    color: var(--text-secondary);
    margin-bottom: var(--spacing-lg);
}

.success-buttons {
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.view-result-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    width: 100%;
    padding: 1rem 2rem;
    background: var(--gradient-success);
    border: none;
    border-radius: 12px;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    font-family: var(--font-heading);
    cursor: pointer;
    transition: all 0.3s ease;
}

.view-result-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(17, 153, 142, 0.4);
}

.view-result-button svg {
    width: 24px;
    height: 24px;
}

.close-button {
    width: 100%;
    padding: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    color: var(--text-secondary);
    font-size: 1rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.close-button:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--text-primary);
}

/* ============================================
   TOAST NOTIFICATIONS
   ============================================ */

.toast-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 2000;
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.toast {
    min-width: 300px;
    padding: 1rem 1.5rem;
    background: var(--bg-glass);
    backdrop-filter: blur(20px);
    border: 1px solid var(--border-glass);
    border-radius: 12px;
    box-shadow: var(--shadow-glass);
    display: flex;
    align-items: center;
    gap: var(--spacing-sm);
    animation: slideInRight 0.3s ease;
}

.toast.success {
    border-left: 4px solid #38ef7d;
}

.toast.error {
    border-left: 4px solid #f5576c;
}

.toast.info {
    border-left: 4px solid #4facfe;
}

.toast-icon svg {
    width: 24px;
    height: 24px;
}

.toast-message {
    flex: 1;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */

@media (max-width: 768px) {
    .page-title {
        font-size: 2rem;
    }

    .page-subtitle {
        font-size: 1rem;
    }

    .form-container {
        padding: var(--spacing-md);
    }

    .aspect-ratio-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .header-content {
        flex-direction: column;
        gap: var(--spacing-sm);
    }

    .username-display {
        display: none;
    }

    .toast-container {
        left: 20px;
        right: 20px;
    }

    .toast {
        min-width: auto;
    }
}

@media (max-width: 480px) {
    .login-card {
        padding: var(--spacing-md);
    }

    .login-title {
        font-size: 1.5rem;
    }

    .page-title {
        font-size: 1.75rem;
    }

    .aspect-ratio-grid {
        grid-template-columns: 1fr;
    }
}
