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

:root {
    --primary: #e53e3e;
    --primary-dark: #c53030;
    --secondary: #4a5568;
    --success: #38a169;
    --gray-50: #f7fafc;
    --gray-100: #edf2f7;
    --gray-200: #e2e8f0;
    --gray-300: #cbd5e1;
    --gray-400: #a0aec0;
    --gray-500: #718096;
    --gray-600: #4a5568;
    --gray-700: #2d3748;
    --gray-800: #1a202c;
    --gray-900: #171923;
    --white: #ffffff;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
    --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--gray-50);
    color: var(--gray-800);
    line-height: 1.6;
}

/* Navbar */
.navbar {
    background: var(--white);
    border-bottom: 1px solid var(--gray-200);
    padding: 1rem 0;
    position: sticky;
    top: 0;
    z-index: 100;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 2rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 700;
    font-size: 1.25rem;
    color: var(--primary);
    text-decoration: none;
}

.nav-logo i {
    font-size: 1.5rem;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 2rem;
    align-items: center;
}

.nav-menu a {
    text-decoration: none;
    color: var(--gray-600);
    font-weight: 500;
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
    transition: all 0.2s;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary);
    background: var(--gray-100);
}

/* Main Content */
.main-content {
    min-height: calc(100vh - 140px);
    padding: 2rem 0;
}

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

/* Page Header */
.page-header {
    text-align: center;
    margin-bottom: 3rem;
}

.tool-icon-large {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, var(--primary), var(--primary-dark));
    border-radius: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: var(--white);
    font-size: 2rem;
}

.page-header h1 {
    font-size: 2.5rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}

.page-header p {
    font-size: 1.1rem;
    color: var(--gray-600);
    max-width: 600px;
    margin: 0 auto;
}

/* Converter Section */
.converter-section {
    background: var(--white);
    border-radius: 12px;
    padding: 2rem;
    box-shadow: var(--shadow);
    margin-bottom: 3rem;
}

.input-section {
    margin-bottom: 2rem;
    text-align: center;
}

#textInput {
    width: 100%;
    min-height: 150px;
    padding: 1rem;
    border: 2px solid var(--gray-300);
    border-radius: 8px;
    font-size: 1rem;
    font-family: inherit;
    resize: vertical;
    margin-bottom: 1rem;
}

#textInput:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 3px rgba(229, 62, 62, 0.1);
}

.generate-section {
    text-align: center;
    margin-bottom: 2rem;
}

.output-section {
    text-align: center;
}

#qrOutput {
    margin-bottom: 2rem;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 200px;
    border: 2px dashed var(--gray-300);
    border-radius: 8px;
    background: var(--gray-50);
    transition: all 0.3s ease;
}

#qrOutput img {
    max-width: 100%;
    height: auto;
    border-radius: 8px;
    box-shadow: var(--shadow-md);
    animation: fadeInScale 0.5s ease-out;
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.8);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

#qrOutput:empty::before {
    content: "QR code will appear here";
    color: var(--gray-500);
    font-style: italic;
}

.btn-primary {
    background: var(--primary);
    color: var(--white);
    border: none;
    padding: 1rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    margin: 0.5rem;
}

.btn-primary:hover {
    background: var(--primary-dark);
    transform: translateY(-1px);
}

.btn-secondary {
    background: var(--gray-100);
    color: var(--gray-700);
    border: none;
    padding: 0.75rem 1.5rem;
    border-radius: 6px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
}

.btn-secondary:hover {
    background: var(--gray-200);
}

/* Features Info */
.features-info {
    margin-top: 4rem;
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
}

.feature-card {
    background: var(--white);
    padding: 1.5rem;
    border-radius: 12px;
    text-align: center;
    box-shadow: var(--shadow);
}

.feature-card i {
    font-size: 2rem;
    color: var(--primary);
    margin-bottom: 1rem;
}

.feature-card h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 0.5rem;
}

.feature-card p {
    color: var(--gray-600);
    font-size: 0.9rem;
}

/* Related Tools Section */
.related-tools-section {
    text-align: center;
    margin: 4rem 0;
}

.related-tools-section h4 {
    font-size: 1.1rem;
    font-weight: 600;
    color: var(--gray-900);
    margin-bottom: 1rem;
}

.related-tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 1rem;
    max-width: 500px;
    margin: 0 auto;
}

.related-tool {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem;
    background: var(--gray-50);
    border: 1px solid var(--gray-200);
    border-radius: 8px;
    text-decoration: none;
    color: var(--gray-700);
    transition: all 0.2s;
    font-size: 0.9rem;
}

.related-tool:hover {
    background: var(--primary);
    color: var(--white);
    transform: translateY(-2px);
}

.related-tool i {
    font-size: 1.5rem;
}

/* SEO Content */
.seo-content {
    margin-top: 4rem;
    background: var(--white);
    border-radius: 12px;
    padding: 3rem 2rem;
    box-shadow: var(--shadow);
}

.seo-section h2 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--gray-900);
    margin-bottom: 1.5rem;
}

.seo-section h3 {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--gray-900);
    margin: 2rem 0 1rem;
}

.seo-section p {
    color: var(--gray-700);
    line-height: 1.8;
    margin-bottom: 1.5rem;
    font-size: 1rem;
}

/* Footer */
.footer {
    background: var(--white);
    border-top: 1px solid var(--gray-200);
    padding: 2rem 0;
    text-align: center;
    color: var(--gray-600);
}

/* Responsive */
@media (max-width: 768px) {
    .nav-container {
        padding: 0 1rem;
    }
    
    .container {
        padding: 0 1rem;
    }
    
    .page-header h1 {
        font-size: 2rem;
    }
    
    .features-grid {
        grid-template-columns: 1fr;
    }
}