﻿:root {
    --primary-color: #4a90e2;
    --secondary-color: #357abd;
    --success-color: #28a745;
    --error-color: #dc3545;
    --background-color: #f5f7fa;
    --card-background: #ffffff;
    --text-color: #333333;
    --nav-height: 60px;
}

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

body {
    font-family: 'Poppins', sans-serif;
    background-color: var(--background-color);
    min-height: 100vh;
    padding-top: var(--nav-height);
    display: flex;
    flex-direction: column;
}

/* Navigation */
.navbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--nav-height);
    background: var(--card-background);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: 1000;
}

.nav-content {
    max-width: 1200px;
    margin: 0 auto;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 1.2rem;
    font-weight: 600;
    color: var(--primary-color);
}

.nav-links {
    display: flex;
    gap: 20px;
    list-style: none;
}

.nav-links a {
    color: var(--text-color);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 20px;
    transition: all 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
    background: var(--primary-color);
    color: white;
}

/* Container and Cards */
.container {
    max-width: 800px;
    margin: 40px auto;
    padding: 0 20px;
    flex: 1;
}

.card {
    background: var(--card-background);
    padding: 2rem;
    border-radius: 15px;
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
    animation: slideIn 0.5s ease;
}

/* Tab Content */
.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

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

/* History Styles */
.history-list {
    margin: 20px 0;
}

.history-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px;
    border-bottom: 1px solid #eee;
    animation: slideIn 0.3s ease;
}

.history-item:last-child {
    border-bottom: none;
}

.history-title {
    flex: 1;
    margin-right: 20px;
}

.history-date {
    color: #666;
    font-size: 0.9rem;
}

.clear-history-btn {
    width: 100%;
    margin-top: 20px;
    background-color: var(--error-color);
}

.clear-history-btn:hover {
    background-color: #c82333;
}

/* About Styles */
.about-content {
    line-height: 1.6;
}

.features, .usage {
    margin: 20px 0;
}

.features ul, .usage ol {
    margin: 10px 0;
    padding-left: 20px;
}

.features li, .usage li {
    margin: 10px 0;
}

.features i {
    color: var(--success-color);
    margin-right: 10px;
}

/* Footer */
.footer {
    text-align: center;
    padding: 20px;
    color: #666;
    background: var(--card-background);
    margin-top: auto;
    box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1);
}

/* Animations */
@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

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

/* Hero Section */
.hero {
    background: linear-gradient(135deg, #007bff, #00bfff);
    color: #fff;
    padding: 60px 20px;
    text-align: center;
}

.hero-content h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

.hero-content p {
    font-size: 1.2rem;
    opacity: 0.9;
}

h1 {
    color: var(--text-color);
    text-align: center;
    margin-bottom: 1.5rem;
    font-size: 2rem;
}

h1 i {
    color: var(--primary-color);
    margin-right: 10px;
}

.size-warning {
    text-align: center;
    color: #666;
    margin-bottom: 1.5rem;
    font-size: 0.9rem;
}

/* Input Group */
.input-group {
    position: relative;
    margin-bottom: 1rem;
}

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

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    padding: 0;
    cursor: pointer;
    color: #666;
}

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

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

button {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 12px 25px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
}

button:hover {
    background-color: var(--secondary-color);
}

.progress-container {
    margin: 1.5rem 0;
}

.progress-label {
    display: flex;
    justify-content: space-between;
    margin-bottom: 8px;
    color: var(--text-color);
    font-size: 0.9rem;
}

.progress-bar {
    height: 8px;
    background-color: #e1e1e1;
    border-radius: 4px;
    overflow: hidden;
}

.progress-fill {
    height: 100%;
    background-color: var(--primary-color);
    width: 0%;
    transition: width 0.3s ease;
}

.progress-status {
    margin-top: 8px;
    color: #666;
    font-size: 0.9rem;
    text-align: center;
}

.status {
    text-align: center;
    margin: 1rem 0;
    padding: 10px;
    border-radius: 8px;
}

.status.error {
    background-color: #fde8e8;
    color: var(--error-color);
}

.status.success {
    background-color: #e8f5e9;
    color: var(--success-color);
}

.download-link {
    text-align: center;
}

.download-button {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background-color: var(--success-color);
    color: white;
    padding: 12px 25px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.3s ease;
}

.download-button:hover {
    background-color: #218838;
}

.loading-spinner {
    display: none;
    flex-direction: column;
    align-items: center;
    gap: 15px;
    margin: 1.5rem 0;
}

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

.expiration-warning {
    color: #666;
    font-size: 0.8rem;
    margin-top: 10px;
    text-align: center;
}

/* Result Section */
.result {
    margin-top: 20px;
    font-size: 1rem;
    color: #333;
}

    .result a {
        color: #007bff;
        text-decoration: none;
        font-weight: 600;
    }

        .result a:hover {
            text-decoration: underline;
        }

/* Error Messages */
.error {
    color: #dc3545;
    font-weight: bold;
    margin-top: 10px;
}

/* Loader */
.loader {
    border: 4px solid #f3f3f3;
    border-top: 4px solid #007bff;
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 20px auto;
    display: none;
}

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

    100% {
        transform: rotate(360deg);
    }
}

/* Responsive Design */
@media (max-width: 480px) {
    .input-group {
        flex-direction: column;
    }
    
    button {
        width: 100%;
        justify-content: center;
    }
}

.auth-form {
    max-width: 400px;
    margin: 0 auto;
}

.auth-form .input-group {
    margin-bottom: 1rem;
}

.auth-form input {
    width: 100%;
}

.auth-switch {
    text-align: center;
    margin-top: 1rem;
}

.auth-switch a {
    color: var(--primary-color);
    text-decoration: none;
}

.auth-switch a:hover {
    text-decoration: underline;
}
