/* Global Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    color: #ffffff;
    line-height: 1.6;
    overflow-x: hidden;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

/* Intro Animation */
.intro-container {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 100vh;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    overflow: hidden;
}

.logo-animation {
    text-align: center;
}

.logo-text {
    font-size: 4rem;
    font-weight: bold;
    color: #ffffff;
    
    
}

.logo-subtext {
    font-size: 1.5rem;
    color: rgba(255, 255, 255, 0.8);
    margin-top: 20px;
    
    
}

.loading-bar {
    width: 200px;
    height: 4px;
    background: rgba(99, 102, 241, 0.3);
    border-radius: 2px;
    margin: 40px auto 0;
    overflow: hidden;
    
    
}

.loading-bar::after {
    content: '';
    display: block;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, #6366f1 0%, #8b5cf6 100%);
    border-radius: 2px;
    animation: loading 2s ease-in-out forwards;
}

@keyframes fadeInUp {
    from {
        
        
    }
    to {
        opacity: 1;
        
    }
}

@keyframes fadeIn {
    from {  }
    to { opacity: 1; }
}

@keyframes loading {
    from { width: 0%; }
    to { width: 100%; }
}

/* Home Page */
.home-container {
    min-height: 100vh;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.logo {
    font-size: 2rem;
    font-weight: bold;
    color: #ffffff;
}

.login-btn {
    padding: 12px 30px;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: #ffffff;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.3);
}

.login-btn:hover {
    
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

.hero-section {
    text-align: center;
    padding: 80px 20px 60px;
    color: #ffffff;
}

.hero-title {
    font-size: 4rem;
    font-weight: 800;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #ffffff 0%, #e0e7ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    letter-spacing: -2px;
}

.hero-subtitle {
    font-size: 1.5rem;
    opacity: 0.8;
    margin-bottom: 50px;
    font-weight: 400;
    letter-spacing: 0.5px;
}

.image-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
    padding: 40px;
}

.image-card {
    background: #1a1a1a;
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 15px;
    overflow: hidden;
}

.image-card:hover {
    border-color: rgba(255, 255, 255, 0.3);
}

.image-card img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    object-position: center;
}

.image-card-content {
    padding: 20px;
}

.image-card-title {
    font-size: 1.3rem;
    color: #ffffff;
    margin-bottom: 10px;
}

.image-card-description {
    color: rgba(255, 255, 255, 0.7);
    line-height: 1.6;
}

/* Image Editor Section */
.editor-section {
    padding: 40px;
}

.editor-container {
    max-width: 1200px;
    margin: 0 auto;
}

.upload-area {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 80px 20px;
    border: 2px dashed rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.02);
    
}

.upload-area:hover {
    border-color: rgba(255, 255, 255, 0.5);
    background: rgba(255, 255, 255, 0.05);
}

.upload-btn {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    padding: 30px 50px;
    background: linear-gradient(135deg, #ffffff 0%, #e0e0e0 100%);
    color: #000000;
    border: none;
    border-radius: 15px;
    font-size: 1.2rem;
    font-weight: 600;
    cursor: pointer;
    
    box-shadow: 0 4px 15px rgba(255, 255, 255, 0.1);
}

.upload-btn:hover {
    
    background: linear-gradient(135deg, #000000 0%, #1a1a1a 100%);
    color: #ffffff;
    box-shadow: 0 8px 25px rgba(255, 255, 255, 0.2);
}

.editor-workspace {
display: flex;
gap: 30px;
flex-wrap: wrap;
}

.canvas-container {
flex: 1;
min-width: 300px;
position: relative;
background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
border: 1px solid rgba(99, 102, 241, 0.2);
border-radius: 15px;
overflow: hidden;
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

#image-canvas {
max-width: 100%;
height: auto;
display: block;
position: relative;
    display: block;
    position: relative;
}

.crop-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.3);
    pointer-events: none;
    display: none;
}

.crop-overlay.active {
    display: block;
}

.crop-box {
    position: absolute;
    border: 3px solid #ffffff;
    background: transparent;
    cursor: move;
    pointer-events: auto;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5);
}

.crop-handle {
    position: absolute;
    width: 16px;
    height: 16px;
    background: #ffffff;
    border: 3px solid #000000;
    pointer-events: auto;
    z-index: 10;
}

.crop-handle.nw {
    top: -8px;
    left: -8px;
    cursor: nw-resize;
}

.crop-handle.ne {
    top: -8px;
    right: -8px;
    cursor: ne-resize;
}

.crop-handle.sw {
    bottom: -8px;
    left: -8px;
    cursor: sw-resize;
}

.crop-handle.se {
    bottom: -8px;
    right: -8px;
    cursor: se-resize;
}

.controls-panel {
    flex: 0 0 300px;
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 15px;
    padding: 25px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.control-group {
    margin-bottom: 25px;
}

.control-group label {
    display: block;
    margin-bottom: 10px;
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    font-weight: 600;
}

.resize-inputs {
    display: flex;
    gap: 15px;
    margin-bottom: 15px;
}

.resize-inputs > div {
    flex: 1;
}

.resize-inputs input {
    width: 100%;
    padding: 12px;
    background: #000000;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 8px;
    color: #ffffff;
    font-size: 0.95rem;
    
}

.resize-inputs input:focus {
    outline: none;
    border-color: #ffffff;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

.control-btn {
    width: 100%;
    padding: 14px 20px;
    background: linear-gradient(135deg, #ffffff 0%, #e0e0e0 100%);
    color: #000000;
    border: none;
    border-radius: 10px;
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    
    box-shadow: 0 2px 10px rgba(255, 255, 255, 0.1);
}

.control-btn:hover {
    background: linear-gradient(135deg, #000000 0%, #1a1a1a 100%);
    color: #ffffff;
    
    box-shadow: 0 4px 20px rgba(255, 255, 255, 0.2);
}

.control-btn.primary {
    background: linear-gradient(135deg, #ffffff 0%, #e0e0e0 100%);
    color: #000000;
}

.control-btn.primary:hover {
    background: linear-gradient(135deg, #000000 0%, #1a1a1a 100%);
    color: #ffffff;
}

.control-btn.secondary {
    background: transparent;
    color: #ffffff;
    border: 2px solid rgba(255, 255, 255, 0.3);
}

.control-btn.secondary:hover {
    background: rgba(255, 255, 255, 0.1);
    border-color: #ffffff;
}

.action-buttons {
    display: flex;
    gap: 10px;
}

/* Auth Pages */
.auth-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    padding: 20px;
}

.auth-card {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 20px;
    padding: 50px;
    max-width: 450px;
    width: 100%;
    
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.auth-title {
    font-size: 2rem;
    font-weight: 800;
    color: #ffffff;
    text-align: center;
    margin-bottom: 30px;
    letter-spacing: -1px;
}

.auth-form {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.form-group {
    display: flex;
    flex-direction: column;
}

.form-group label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.7);
    margin-bottom: 8px;
    font-weight: 500;
}

.form-group input {
    padding: 15px;
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 10px;
    font-size: 1rem;
    background: #000000;
    color: #ffffff;
    
}

.form-group input:focus {
    outline: none;
    border-color: #ffffff;
    box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.1);
}

.auth-btn {
    padding: 15px;
    background: linear-gradient(135deg, #ffffff 0%, #e0e0e0 100%);
    color: #000000;
    border: none;
    border-radius: 10px;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    
    margin-top: 10px;
    box-shadow: 0 2px 10px rgba(255, 255, 255, 0.1);
}

.auth-btn:hover {
    
    background: linear-gradient(135deg, #000000 0%, #1a1a1a 100%);
    color: #ffffff;
    box-shadow: 0 4px 20px rgba(255, 255, 255, 0.2);
}

.auth-link {
    text-align: center;
    margin-top: 20px;
    color: rgba(255, 255, 255, 0.7);
}

.auth-link a {
    color: #ffffff;
    text-decoration: none;
    font-weight: 600;
}

.auth-link a:hover {
    text-decoration: underline;
}

.error-message {
    background: rgba(255, 0, 0, 0.1);
    color: #ff6b6b;
    padding: 10px;
    border-radius: 8px;
    font-size: 0.9rem;
    display: none;
    border: 1px solid rgba(255, 0, 0, 0.2);
}

.success-message {
    background: rgba(0, 255, 0, 0.1);
    color: #51cf66;
    padding: 10px;
    border-radius: 8px;
    font-size: 0.9rem;
    display: none;
    border: 1px solid rgba(0, 255, 0, 0.2);
}

/* Dashboard */
.dashboard-container {
    min-height: 100vh;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
}

.dashboard-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    background: rgba(99, 102, 241, 0.1);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.dashboard-content {
    padding: 40px;
    color: #ffffff;
}

.welcome-section {
    text-align: center;
    padding: 60px 20px;
}

.welcome-title {
    font-size: 2.5rem;
    margin-bottom: 20px;
    background: linear-gradient(135deg, #ffffff 0%, #e0e7ff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.welcome-text {
    font-size: 1.2rem;
    opacity: 0.9;
}

.header-actions {
    display: flex;
    gap: 20px;
    align-items: center;
}

.profile-icon {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.3);
}

.profile-icon:hover {
    
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

.profile-icon svg {
    width: 25px;
    height: 25px;
    fill: #ffffff;
}

.logout-btn {
    padding: 10px 25px;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: #ffffff;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.3);
}

.logout-btn:hover {
    
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

/* Profile Page */
.profile-container {
    min-height: 100vh;
    background: linear-gradient(135deg, #0f172a 0%, #1e293b 100%);
    padding: 40px;
}

.profile-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 40px;
    background: rgba(99, 102, 241, 0.1);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(99, 102, 241, 0.2);
}

.profile-card {
    background: linear-gradient(135deg, #1e293b 0%, #0f172a 100%);
    border: 1px solid rgba(99, 102, 241, 0.2);
    border-radius: 20px;
    padding: 50px;
    max-width: 600px;
    margin: 50px auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
}

.profile-avatar {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto 30px;
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.3);
}

.profile-avatar svg {
    width: 60px;
    height: 60px;
    fill: #ffffff;
}

.profile-info {
    text-align: center;
}

.profile-email {
    font-size: 1.5rem;
    color: #ffffff;
    margin-bottom: 10px;
    font-weight: 600;
}

.profile-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.5);
    text-transform: uppercase;
    letter-spacing: 1px;
}

.back-btn {
    padding: 12px 30px;
    background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
    color: #ffffff;
    border: none;
    border-radius: 25px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    
    margin-top: 30px;
    box-shadow: 0 2px 10px rgba(99, 102, 241, 0.3);
}

.back-btn:hover {
    
    box-shadow: 0 4px 20px rgba(99, 102, 241, 0.4);
}

/* Responsive */
@media (max-width: 768px) {
    .hero-title {
        font-size: 2.5rem;
    }
    
    .header {
        padding: 15px 20px;
    }
    
    .image-gallery {
        grid-template-columns: 1fr;
    }
    
    .auth-card {
        padding: 30px;
    }
    
    .dashboard-header,
    .profile-header {
        padding: 15px 20px;
    }
}
