:root {
    --primary-blue: #3B82F6;
    --primary-purple: #8B5CF6;
    --gradient: linear-gradient(135deg, #3B82F6, #8B5CF6);
    --text-dark: #1F2937;
    --bg-light: #F9FAFB;
    --error-color: #EF4444;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Inter', sans-serif;
    color: var(--text-dark);
    line-height: 1.6;
    overflow-x: hidden;
    background: linear-gradient(to bottom, #FFFFFF 0%, rgba(255, 255, 255, 0) 50%, var(--gradient) 100%);
    min-height: 100vh;
}

nav {
    background: var(--gradient);
    padding: 10px 15px;
    position: sticky;
    top: 0;
    z-index: 100;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

nav ul {
    list-style: none;
    display: flex;
    gap: 20px;
    flex-wrap: wrap;
}

nav a {
    color: white;
    text-decoration: none;
    font-weight: 600;
    font-size: 1em;
    transition: color 0.3s ease;
}

nav a:hover {
    color: #E2E8F0;
}

.hamburger {
    display: none;
    font-size: 1.8em;
    color: white;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 8px;
    z-index: 101;
    transition: transform 0.2s ease, opacity 0.2s ease;
}

.hamburger:hover {
    opacity: 0.8;
    transform: scale(1.1);
}

.nav-menu {
    display: flex;
}

@media (max-width: 768px) {
    .hamburger {
        display: block;
        display: visible;
    }
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--gradient);
        flex-direction: column;
        padding: 15px;
        box-shadow: 0 4px 10px rgba(0,0,0,0.2);
    }
    .nav-menu.active {
        display: flex;
    }
    nav ul {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }
    nav li {
        width: 100%;
    }
    nav a {
        display: block;
        padding: 10px;
        font-size: 1.1em;
    }
}

header {
    background-size: 100% auto;
    background-position: center top;
    background-repeat: no-repeat;
    width: 100%;
    height: auto;
    animation: fadeInDown 1s ease-out;
    margin-bottom: 50px;
}

.container {
    max-width: 900px;
    margin: 20px auto;
    padding: 0 15px;
}

.section {
    background: white;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 4px 15px rgba(0,0,0,0.1);
    margin-bottom: 30px;
    opacity: 0;
}

.section.visible {
    animation: fadeInUp 0.8s ease-out forwards;
}

.section h2 {
    color: var(--primary-blue);
    margin-bottom: 15px;
    font-size: 1.8em;
}

.section h3 {
    color: var(--primary-purple);
    margin: 15px 0 10px;
    font-size: 1.4em;
}

.faq h3, .blog h3, .resources h3, .community h3 {
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq h3::after, .blog h3::after, .resources h3::after, .community h3::after {
    content: '▼';
    font-size: 0.7em;
    transition: transform 0.3s ease;
}

.faq h3.open::after, .blog h3.open::after, .resources h3.open::after, .community h3.open::after {
    transform: rotate(180deg);
}

.generator {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.input-group, .customization-group {
    margin-bottom: 20px;
    opacity: 0;
    padding: 8px;
    border-radius: 6px;
    transition: background-color 0.3s ease;
}

.input-group.visible, .customization-group.visible {
    animation: fadeInLeft 0.5s ease-out forwards;
}

.input-group:nth-child(1) { animation-delay: 0.1s; }
.customization-group:nth-child(1) { animation-delay: 0.2s; }
.customization-group:nth-child(2) { animation-delay: 0.3s; }
.customization-group:nth-child(3) { animation-delay: 0.4s; }
.customization-group:nth-child(4) { animation-delay: 0.5s; }
.customization-group:nth-child(5) { animation-delay: 0.6s; }
.customization-group:nth-child(6) { animation-delay: 0.7s; }
.customization-group:nth-child(7) { animation-delay: 0.8s; }

label {
    display: block;
    font-weight: 600;
    margin-bottom: 6px;
    font-size: 1em;
}

input[type="text"], select, input[type="color"], input[type="number"], input[type="checkbox"], input[type="file"] {
    width: 100%;
    padding: 10px;
    border: 1px solid #D1D5DB;
    border-radius: 6px;
    font-size: 0.9em;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
}

input:focus, select:focus {
    outline: none;
    border-color: var(--primary-purple);
    box-shadow: 0 0 0 3px rgba(139, 92, 246, 0.2);
}

button {
    background: var(--gradient);
    color: white;
    padding: 12px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 1.1em;
    width: 100%;
    min-height: 48px;
    transition: transform 0.2s ease, opacity 0.2s ease;
    opacity: 0;
}

button.visible {
    animation: zoomIn 0.5s ease-out forwards;
}

button:hover {
    transform: scale(1.03);
    opacity: 1;
}

button:disabled {
    background: #9CA3AF;
    cursor: not-allowed;
    opacity: 0.6;
}

#qrcode {
    margin-top: 20px;
    text-align: center;
    animation: zoomIn 0.5s ease-in;
}

#downloadBtn {
    display: none;
    background: linear-gradient(135deg, #6D28D9, #3B82F6);
    margin-top: 15px;
}

#error {
    color: var(--error-color);
    margin-top: 10px;
    display: none;
    text-align: center;
    animation: shake 0.5s ease;
}

.how-to, .about, .faq, .blog, .tutorials, .use-cases, .resources, .community {
    background: #F3E8FF;
}

.how-to ol, .tutorials ol, .use-cases ul {
    padding-left: 25px;
    margin: 15px 0;
}

.faq ul, .blog ul, .resources ul, .community ul {
    list-style: none;
    padding-left: 0;
}

.faq li, .blog li, .resources li, .community li {
    margin-bottom: 15px;
}

.faq article, .blog article, .resources article, .community article {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease, padding 0.3s ease;
    padding: 0 10px;
    opacity: 0;
}

.faq article.open, .blog article.open, .resources article.open, .community article.open {
    max-height: 1000px;
    padding: 10px;
    animation: fadeIn 0.5s ease-out forwards;
}

.preview-logo {
    max-width: 100px;
    margin-top: 10px;
    display: none;
    border-radius: 6px;
}

.loader {
    display: none;
    border: 3px solid #E5E7EB;
    border-top: 3px solid var(--primary-purple);
    border-radius: 50%;
    width: 30px;
    height: 30px;
    animation: spin 1s linear infinite;
    margin: 15px auto;
}

.blog a, .tutorials a, .use-cases a, .resources a, .community a {
    color: var(--primary-blue);
    text-decoration: none;
}

.blog a:hover, .tutorials a:hover, .use-cases a:hover, .resources a:hover, .community a:hover {
    text-decoration: underline;
}

@keyframes slideDown {
    from { transform: translateY(-100%); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeInDown {
    from { transform: translateY(-50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeInUp {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

@keyframes fadeInLeft {
    from { transform: translateX(-30px); opacity: 0; }
    to { transform: translateX(0); opacity: 1; }
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes zoomIn {
    from { transform: scale(0.8); opacity: 0; }
    to { transform: scale(1); opacity: 1; }
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

@keyframes pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.05); }
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

@media (max-width: 768px) {
    nav ul {
        flex-direction: column;
        gap: 10px;
        align-items: center;
    }
    .section h2 { font-size: 1.5em; }
    .section h3 { font-size: 1.2em; }
    .container { padding: 0 10px; }
    button { font-size: 1em; }
    input[type="text"], select, input[type="color"], input[type="number"], input[type="file"] {
        font-size: 0.85em;
    }
}