/* PasswordGen - ZLabs Branding (Red Theme) */

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

:root {
    --primary-color: #10b981;
    --primary-hover: #059669;
    --primary-dark: #047857;
    --secondary-color: #64748b;
    --success-color: #10b981;
    --warning-color: #f59e0b;
    --background: #ffffff;
    --surface: #f8fafc;
    --border: #e2e8f0;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background-color: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.container {
    max-width: 1000px;
    margin: 0 auto;
    padding: 0 2rem;
}

/* Header */
header {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    padding: 1.25rem 0;
    box-shadow: var(--shadow-lg);
}

.logo-container {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    margin-bottom: 0.25rem;
}

.logo {
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.15);
    border-radius: 10px;
    padding: 8px;
    backdrop-filter: blur(10px);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.logo svg {
    width: 100%;
    height: 100%;
    display: block;
}

header h1 {
    font-size: 3rem;
    font-weight: 700;
    margin: 0;
    letter-spacing: -0.5px;
}

header .subtitle {
    font-size: 1rem;
    opacity: 0.95;
    text-align: center;
}

/* Main */
main {
    flex: 1;
    padding: 2rem 0;
}

/* Privacy Notice */
.privacy-notice {
    background: #f0fdf4;
    border: 1px solid #86efac;
    border-radius: 8px;
    padding: 1rem;
    margin-bottom: 2rem;
    text-align: center;
}

.privacy-notice p {
    margin: 0;
    color: #065f46;
    font-weight: 500;
}

/* Generator Section */
.generator-section {
    margin-bottom: 2rem;
}

.password-display {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

#passwordOutput {
    flex: 1;
    padding: 1rem 1.5rem;
    font-size: 1.25rem;
    font-family: 'Monaco', 'Menlo', 'Courier New', monospace;
    border: 2px solid var(--border);
    border-radius: 8px;
    background: white;
    color: var(--text-primary);
}

.password-actions {
    display: flex;
    gap: 0.5rem;
}

.btn-icon {
    width: 50px;
    height: 50px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border);
    background: white;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
    color: var(--text-secondary);
}

.btn-icon:hover {
    background: var(--primary-color);
    border-color: var(--primary-color);
    color: white;
    transform: translateY(-1px);
}

/* Strength Meter */
.strength-meter {
    background: white;
    border: 1px solid var(--border);
    border-radius: 8px;
    padding: 1rem 1.5rem;
}

.strength-label {
    font-weight: 500;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
}

.strength-bar {
    height: 8px;
    background: var(--surface);
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.strength-fill {
    height: 100%;
    transition: all 0.3s;
    width: 0%;
}

.strength-fill.weak {
    background: #ef4444;
    width: 25%;
}

.strength-fill.fair {
    background: #f59e0b;
    width: 50%;
}

.strength-fill.good {
    background: #3b82f6;
    width: 75%;
}

.strength-fill.strong {
    background: #10b981;
    width: 100%;
}

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

.strength-text.weak { color: #ef4444; }
.strength-text.fair { color: #f59e0b; }
.strength-text.good { color: #3b82f6; }
.strength-text.strong { color: #10b981; }

/* Settings Section */
.settings-section {
    margin-bottom: 2rem;
}

.settings-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: var(--shadow);
}

.settings-card h3 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-size: 1.25rem;
}

.setting-item {
    margin-bottom: 1.25rem;
}

.setting-item label {
    display: block;
    font-weight: 500;
    color: var(--text-primary);
    margin-bottom: 0.5rem;
}

.setting-item input[type="range"] {
    width: 100%;
    height: 6px;
    border-radius: 3px;
    background: var(--surface);
    outline: none;
    -webkit-appearance: none;
}

.setting-item input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
}

.setting-item input[type="range"]::-moz-range-thumb {
    width: 18px;
    height: 18px;
    border-radius: 50%;
    background: var(--primary-color);
    cursor: pointer;
    border: none;
}

.setting-item input[type="checkbox"] {
    margin-right: 0.5rem;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

#lengthValue {
    color: var(--primary-color);
    font-weight: 600;
}

/* Batch Section */
.batch-section {
    margin-bottom: 2rem;
}

.batch-card {
    background: white;
    border: 1px solid var(--border);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: var(--shadow);
}

.batch-card h3 {
    margin-bottom: 1.5rem;
    color: var(--text-primary);
    font-size: 1.25rem;
}

.batch-controls {
    display: flex;
    gap: 1rem;
    align-items: center;
    margin-bottom: 1.5rem;
}

.batch-controls label {
    font-weight: 500;
    color: var(--text-primary);
}

.batch-controls input[type="number"] {
    width: 100px;
    padding: 0.5rem;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-size: 1rem;
}

.batch-output {
    background: var(--surface);
    border-radius: 8px;
    padding: 1rem;
    max-height: 300px;
    overflow-y: auto;
}

.batch-password {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    background: white;
    border: 1px solid var(--border);
    border-radius: 6px;
    font-family: 'Monaco', 'Menlo', 'Courier New', monospace;
    font-size: 0.9rem;
}

.batch-password:last-child {
    margin-bottom: 0;
}

.batch-password button {
    padding: 0.25rem 0.75rem;
    font-size: 0.75rem;
}

/* Buttons */
.btn {
    padding: 0.625rem 1.25rem;
    border: none;
    border-radius: 6px;
    font-size: 0.9rem;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    font-family: inherit;
}

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

.btn-primary:hover:not(:disabled) {
    background: var(--primary-hover);
    transform: translateY(-1px);
    box-shadow: 0 4px 6px rgba(16, 185, 129, 0.3);
}

.btn-secondary {
    background: white;
    color: var(--text-primary);
    border: 1px solid var(--border);
}

.btn-secondary:hover:not(:disabled) {
    background: var(--surface);
    border-color: var(--secondary-color);
}

.btn-large {
    width: 100%;
    padding: 1rem 2rem;
    font-size: 1.1rem;
    margin-top: 1rem;
}

.btn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* Info Section */
.info-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-bottom: 3rem;
}

.info-card {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border);
    box-shadow: var(--shadow);
}

.info-card h3 {
    color: var(--text-primary);
    font-size: 1.1rem;
    margin-bottom: 0.75rem;
}

.info-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
    margin: 0;
}

/* Tips Section */
.tips-section {
    background: var(--surface);
    padding: 3rem 2rem;
    border-radius: 12px;
    margin-bottom: 3rem;
}

.tips-section h2 {
    text-align: center;
    font-size: 2rem;
    margin-bottom: 2rem;
    color: var(--text-primary);
}

.tips-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
}

.tip-card {
    background: white;
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border);
}

.tip-card h4 {
    color: var(--text-primary);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.tip-card p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 0;
}

/* Footer */
footer {
    background: linear-gradient(to bottom, #f8fafc 0%, #ffffff 100%);
    border-top: 1px solid var(--border);
    padding: 2rem 0 1rem;
    margin-top: auto;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}

.footer-section h3 {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.footer-section p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    line-height: 1.6;
    margin-bottom: 0.5rem;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    color: var(--text-secondary);
    font-size: 0.9rem;
    padding: 0.25rem 0;
    padding-left: 1.5rem;
    position: relative;
}

.footer-section ul li::before {
    content: "✓";
    position: absolute;
    left: 0;
    color: var(--success-color);
    font-weight: bold;
}

.footer-email a {
    color: #8b5cf6;
    text-decoration: none;
    font-weight: 600;
}

.footer-email a:hover {
    text-decoration: underline;
}

.footer-note {
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid var(--border);
}

.footer-bottom p {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin: 0;
}

.footer-bottom a {
    color: #8b5cf6;
    text-decoration: none;
    font-weight: 600;
}

.footer-bottom a:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 768px) {
    header h1 {
        font-size: 2rem;
    }

    .logo {
        width: 50px;
        height: 50px;
    }

    .container {
        padding: 0 1rem;
    }

    .password-display {
        flex-direction: column;
    }

    .password-actions {
        justify-content: center;
    }

    .batch-controls {
        flex-direction: column;
        align-items: stretch;
    }

    .batch-controls input[type="number"] {
        width: 100%;
    }

    .tips-grid {
        grid-template-columns: 1fr;
    }
}
