﻿:root {
    --primary-color: #6366f1;
    --primary-dark: #4f46e5;
    --primary-light: #818cf8;
    --success-color: #10b981;
    --success-dark: #059669;
    --background: #f8fafc;
    --surface: #ffffff;
    --text-primary: #1e293b;
    --text-secondary: #64748b;
    --border-color: #e2e8f0;
    --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
    --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
    --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
    --shadow-xl: 0 20px 25px -5px rgb(0 0 0 / 0.1);
}

body {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    padding: 1rem;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.key-generator-container {
    max-width: 1100px;
    width: 100%;
}

.header-section {
    text-align: center;
    color: white;
    margin-bottom: 1.5rem;
}

.icon-wrapper {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 60px;
    height: 60px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    border-radius: 16px;
    margin-bottom: 0.75rem;
    box-shadow: var(--shadow-lg);
}

.icon-wrapper svg {
    filter: drop-shadow(0 2px 4px rgba(0, 0, 0, 0.1));
    width: 36px;
    height: 36px;
}

.header-section h1 {
    font-size: 2rem;
    font-weight: 700;
    margin: 0 0 0.25rem 0;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.subtitle {
    font-size: 1rem;
    opacity: 0.9;
    margin: 0;
}

.content-wrapper {
    background: var(--surface);
    border-radius: 20px;
    padding: 2rem;
    box-shadow: var(--shadow-xl);
}

.generator-form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1rem;
}

.form-group {
    display: grid;
    grid-template-columns: 180px 1fr;
    align-items: center;
    gap: 1rem;
}

.form-label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0;
}

.form-label svg {
    color: var(--primary-color);
    width: 16px;
    height: 16px;
}

.radio-group {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 0.75rem;
}

.radio-card {
    position: relative;
    display: flex;
    cursor: pointer;
    border: 2px solid var(--border-color);
    border-radius: 10px;
    padding: 0.75rem 1rem;
    transition: all 0.2s ease;
    background: var(--surface);
}

.radio-card:hover {
    border-color: var(--primary-light);
    box-shadow: var(--shadow-sm);
}

.radio-card input[type="radio"] {
    position: absolute;
    opacity: 0;
    width: 0;
    height: 0;
}

.radio-card input[type="radio"]:checked + .radio-content {
    color: var(--primary-color);
}

.radio-card input[type="radio"]:checked ~ .radio-content::before {
    content: '';
    position: absolute;
    top: 50%;
    right: 10px;
    transform: translateY(-50%);
    width: 16px;
    height: 16px;
    background: var(--primary-color);
    border-radius: 50%;
}

.radio-card input[type="radio"]:checked ~ .radio-content::after {
    content: '✓';
    position: absolute;
    top: 50%;
    right: 14px;
    transform: translateY(-50%);
    color: white;
    font-size: 11px;
    font-weight: bold;
}

.radio-card:has(input[type="radio"]:checked) {
    border-color: var(--primary-color);
    background: rgba(99, 102, 241, 0.05);
}

.radio-content {
    display: flex;
    flex-direction: column;
    gap: 0.125rem;
    position: relative;
    width: 100%;
    padding-right: 28px;
}

.radio-title {
    font-size: 0.9375rem;
    font-weight: 600;
    color: var(--text-primary);
}

.radio-desc {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

.btn-generate {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    border-radius: 10px;
    padding: 0.875rem 2rem;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 6px rgba(99, 102, 241, 0.3);
    margin-top: 0.5rem;
}

.btn-generate:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 10px rgba(99, 102, 241, 0.4);
}

.btn-generate:active {
    transform: translateY(0);
}

.btn-generate svg {
    width: 18px;
    height: 18px;
}

.result-section {
    padding-top: 1.5rem;
    border-top: 2px solid var(--border-color);
    animation: slideIn 0.5s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-header {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--success-color);
    margin-bottom: 1rem;
}

.result-header svg {
    flex-shrink: 0;
    width: 20px;
    height: 20px;
}

.result-header h3 {
    margin: 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.key-display {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border: 2px solid var(--border-color);
    border-radius: 12px;
    padding: 1.25rem;
    margin-bottom: 1rem;
    text-align: center;
}

.key-display label {
    display: block;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 0.75rem;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.key-value {
    font-family: 'Courier New', monospace;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    letter-spacing: 0.1em;
    margin-bottom: 1rem;
    word-break: break-all;
}

.btn-copy {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: white;
    border: none;
    border-radius: 8px;
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-copy:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(99, 102, 241, 0.3);
}

.btn-copy svg {
    width: 16px;
    height: 16px;
}

.key-details {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 1rem;
    background: var(--background);
    border-radius: 10px;
    padding: 1rem;
}

.detail-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.detail-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.detail-value {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
}

.text-danger {
    color: #ef4444;
    font-size: 0.75rem;
    margin-top: 0.25rem;
}

.app-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding: 1rem 0;
}

.app-footer p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.875rem;
    margin: 0;
    font-weight: 500;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.app-footer a {
    color: rgba(255, 255, 255, 1);
    text-decoration: none;
    font-weight: 600;
    transition: all 0.2s ease;
    border-bottom: 1px solid transparent;
}

.app-footer a:hover {
    color: rgba(255, 255, 255, 1);
    border-bottom: 1px solid rgba(255, 255, 255, 0.8);
}

@media (max-width: 992px) {
    .form-group {
        grid-template-columns: 1fr;
        gap: 0.75rem;
    }

    .radio-group {
        grid-template-columns: 1fr;
    }

    .key-details {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 640px) {
    body {
        padding: 0.5rem;
    }

    .content-wrapper {
        padding: 1.5rem;
        border-radius: 16px;
    }

    .header-section h1 {
        font-size: 1.5rem;
    }

    .key-value {
        font-size: 1.125rem;
    }

    .key-details {
        grid-template-columns: 1fr;
    }

    .app-footer {
        margin-top: 1rem;
        padding: 0.75rem 0;
    }

    .app-footer p {
        font-size: 0.8125rem;
    }
}
