:root {
    --primary: #10b981;
    --primary-hover: #059669;
    --primary-glow: rgba(16, 185, 129, 0.3);
    --secondary: #6366f1;
    --bg-dark: #0a0f1a;
    --bg-card: #111827;
    --bg-input: #1f2937;
    --text-main: #f9fafb;
    --text-muted: #9ca3af;
    --accent: #f59e0b;
    --danger: #ef4444;
    --success: #22c55e;
    --radius: 12px;
    --glass: rgba(17, 24, 39, 0.8);
    --border: rgba(255, 255, 255, 0.08);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
}

body {
    background-color: var(--bg-dark);
    background-image:
        radial-gradient(ellipse at 20% 20%, rgba(16, 185, 129, 0.08) 0%, transparent 50%),
        radial-gradient(ellipse at 80% 80%, rgba(99, 102, 241, 0.08) 0%, transparent 50%);
    color: var(--text-main);
    line-height: 1.6;
    overflow-x: hidden;
    min-height: 100vh;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Header */
header {
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border);
    backdrop-filter: blur(20px);
    position: sticky;
    top: 0;
    z-index: 100;
    background: rgba(10, 15, 26, 0.9);
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 22px;
    font-weight: 800;
    background: linear-gradient(135deg, #10b981 0%, #34d399 50%, #6ee7b7 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-decoration: none;
}

.logo i {
    color: var(--primary);
    -webkit-text-fill-color: var(--primary);
}

nav ul {
    display: flex;
    list-style: none;
    gap: 30px;
}

nav a {
    color: var(--text-muted);
    text-decoration: none;
    font-weight: 500;
    font-size: 15px;
    transition: all 0.3s ease;
    position: relative;
}

nav a:hover {
    color: var(--primary);
}

nav a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

nav a:hover::after {
    width: 100%;
}

.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    color: var(--text-main);
    cursor: pointer;
}

/* Hero Section */
.hero {
    padding: 80px 0 60px;
    text-align: center;
}

.hero h1 {
    font-size: 3.5rem;
    font-weight: 900;
    margin-bottom: 20px;
    letter-spacing: -0.03em;
    background: linear-gradient(135deg, #fff 0%, #10b981 50%, #34d399 100%);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 60px rgba(16, 185, 129, 0.3);
}

.hero p {
    font-size: 1.2rem;
    color: var(--text-muted);
    max-width: 700px;
    margin: 0 auto;
}

/* Converter Card */
.converter-container {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 24px;
    padding: 40px;
    box-shadow:
        0 25px 50px -12px rgba(0, 0, 0, 0.5),
        0 0 0 1px rgba(16, 185, 129, 0.1);
    max-width: 900px;
    margin: 40px auto 80px;
    position: relative;
}

.converter-container::before {
    content: '';
    position: absolute;
    top: -1px;
    left: 50%;
    transform: translateX(-50%);
    width: 200px;
    height: 3px;
    background: linear-gradient(90deg, transparent, var(--primary), transparent);
    border-radius: 3px;
}

/* Mode Selector */
.mode-selector {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-bottom: 30px;
}

.mode-btn {
    background: var(--bg-input);
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 14px 12px;
    border-radius: 12px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.mode-btn:hover {
    border-color: var(--primary);
    color: var(--text-main);
}

.mode-btn.active {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.2), rgba(16, 185, 129, 0.1));
    border-color: var(--primary);
    color: var(--primary);
    box-shadow: 0 0 20px rgba(16, 185, 129, 0.2);
}

.mode-btn i {
    width: 16px;
    height: 16px;
}

/* Input Section */
.input-section {
    margin-bottom: 30px;
}

.input-group {
    position: relative;
}

.input-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.input-group label i {
    width: 16px;
    height: 16px;
    color: var(--primary);
}

.input-group input {
    width: 100%;
    background: var(--bg-input);
    border: 2px solid var(--border);
    color: var(--text-main);
    padding: 20px 24px;
    border-radius: 16px;
    font-size: 24px;
    font-family: 'JetBrains Mono', monospace;
    font-weight: 500;
    outline: none;
    transition: all 0.3s ease;
    letter-spacing: 2px;
}

.input-group input:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.1);
}

.input-group input::placeholder {
    color: var(--text-muted);
    opacity: 0.5;
    font-size: 16px;
    letter-spacing: normal;
}

.input-hint {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-top: 10px;
    font-size: 13px;
    color: var(--text-muted);
}

.input-hint i {
    width: 14px;
    height: 14px;
}

/* Base Selectors */
.base-selectors {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    gap: 20px;
    align-items: end;
    margin-top: 20px;
}

.base-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.base-group label {
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
}

.base-group select {
    background: var(--bg-input);
    border: 1px solid var(--border);
    color: var(--text-main);
    padding: 14px 18px;
    border-radius: 10px;
    font-size: 14px;
    outline: none;
    cursor: pointer;
}

.swap-btn {
    background: var(--primary);
    border: none;
    color: white;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
}

.swap-btn:hover {
    transform: rotate(180deg);
    background: var(--primary-hover);
}

/* Convert Button */
.convert-btn {
    width: 100%;
    background: linear-gradient(135deg, var(--primary) 0%, #059669 100%);
    color: white;
    border: none;
    padding: 18px;
    border-radius: 14px;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    box-shadow: 0 10px 30px rgba(16, 185, 129, 0.3);
}

.convert-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 40px rgba(16, 185, 129, 0.4);
}

.convert-btn i {
    width: 20px;
    height: 20px;
}

/* Results Section */
.results-section {
    margin-top: 40px;
    padding-top: 40px;
    border-top: 1px solid var(--border);
}

.results-section>h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 25px;
    font-size: 18px;
    color: var(--success);
}

.results-section>h3 i {
    width: 22px;
    height: 22px;
}

.result-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
}

.result-card {
    background: var(--bg-input);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 20px;
    position: relative;
}

.result-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-muted);
    margin-bottom: 12px;
}

.result-label i {
    width: 16px;
    height: 16px;
    color: var(--primary);
}

.result-value {
    font-family: 'JetBrains Mono', monospace;
    font-size: 18px;
    font-weight: 600;
    color: var(--text-main);
    word-break: break-all;
    line-height: 1.4;
    padding-right: 40px;
}

.copy-btn {
    position: absolute;
    top: 20px;
    right: 20px;
    background: rgba(16, 185, 129, 0.1);
    border: none;
    color: var(--primary);
    width: 36px;
    height: 36px;
    border-radius: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.copy-btn:hover {
    background: var(--primary);
    color: white;
}

.copy-btn i {
    width: 16px;
    height: 16px;
}

/* Step by Step */
.step-by-step {
    margin-top: 30px;
    background: rgba(16, 185, 129, 0.05);
    border: 1px solid rgba(16, 185, 129, 0.2);
    border-radius: 16px;
    padding: 25px;
}

.step-by-step h4 {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 20px;
    font-size: 16px;
    color: var(--primary);
}

.step-by-step h4 i {
    width: 18px;
    height: 18px;
}

.steps-content {
    font-family: 'JetBrains Mono', monospace;
    font-size: 14px;
    color: var(--text-muted);
    line-height: 2;
}

.steps-content .step {
    padding: 8px 0;
    border-bottom: 1px dashed var(--border);
}

.steps-content .step:last-child {
    border-bottom: none;
}

.steps-content .highlight {
    color: var(--primary);
    font-weight: 600;
}

/* Quick Examples */
.quick-examples {
    margin-top: 30px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-wrap: wrap;
}

.example-label {
    font-size: 13px;
    color: var(--text-muted);
}

.example-btn {
    background: var(--bg-input);
    border: 1px solid var(--border);
    color: var(--text-muted);
    padding: 8px 16px;
    border-radius: 8px;
    font-family: 'JetBrains Mono', monospace;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.example-btn:hover {
    border-color: var(--primary);
    color: var(--primary);
}

/* Features */
.features {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-bottom: 100px;
}

.feature-card {
    padding: 30px;
    background: var(--glass);
    border: 1px solid var(--border);
    border-radius: 20px;
    transition: all 0.3s ease;
}

.feature-card:hover {
    border-color: var(--primary);
    transform: translateY(-5px);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.feature-card.tool-link:hover {
    background: rgba(16, 185, 129, 0.05);
}

.feature-card i {
    font-size: 32px;
    color: var(--primary);
    margin-bottom: 20px;
    display: block;
}

.feature-card h3,
.feature-card h4 {
    margin-bottom: 12px;
    font-size: 18px;
}

.feature-card p {
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.6;
}

.feature-card img {
    object-fit: cover;
    height: 180px;
}

/* Content Area */
.content-area {
    margin-bottom: 100px;
}

.content-section {
    margin-bottom: 60px;
}

.content-section h2 {
    font-size: 2.2rem;
    margin-bottom: 25px;
    color: var(--text-main);
}

.content-section h3 {
    font-size: 1.4rem;
    margin: 30px 0 15px;
    color: var(--primary);
}

.content-section p {
    margin-bottom: 18px;
    color: var(--text-muted);
    font-size: 16px;
    line-height: 1.8;
}

.content-section a {
    color: var(--primary);
    text-decoration: none;
}

.content-section a:hover {
    text-decoration: underline;
}

/* FAQ Section */
.faq-section {
    margin-bottom: 100px;
}

.faq-section h2 {
    font-size: 2rem;
    margin-bottom: 40px;
    text-align: center;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
}

.faq-item {
    background: var(--bg-card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 25px;
}

.faq-item h3 {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 16px;
    margin-bottom: 15px;
    color: var(--text-main);
}

.faq-item h3 i {
    width: 18px;
    height: 18px;
    color: var(--accent);
}

.faq-item p {
    color: var(--text-muted);
    font-size: 14px;
    line-height: 1.7;
}

/* Related Tools & Articles Preview */
.related-tools,
.articles-preview {
    margin-bottom: 100px;
}

/* Footer */
footer {
    background: #050810;
    padding: 80px 0 40px;
    border-top: 1px solid var(--border);
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    margin-bottom: 60px;
}

.footer-about .logo {
    margin-bottom: 20px;
}

.footer-about p {
    color: var(--text-muted);
    font-size: 14px;
    max-width: 280px;
    line-height: 1.7;
}

.footer-links h4 {
    margin-bottom: 25px;
    font-size: 16px;
}

.footer-links ul {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: var(--text-muted);
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: var(--primary);
}

.footer-bottom {
    text-align: center;
    color: var(--text-muted);
    font-size: 13px;
    border-top: 1px solid var(--border);
    padding-top: 40px;
}

/* Responsive */
@media (max-width: 992px) {
    .features {
        grid-template-columns: repeat(2, 1fr);
    }

    .footer-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .mode-selector {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.2rem;
    }

    .hero p {
        font-size: 1rem;
    }

    .features {
        grid-template-columns: 1fr;
    }

    .faq-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-about p {
        max-width: 100%;
    }

    .result-grid {
        grid-template-columns: 1fr;
    }

    .mode-selector {
        grid-template-columns: 1fr;
    }

    .base-selectors {
        grid-template-columns: 1fr;
        gap: 15px;
    }

    .swap-btn {
        width: 100%;
        height: 40px;
    }

    nav ul {
        display: none;
    }

    .mobile-menu-btn {
        display: block;
    }

    .converter-container {
        padding: 25px;
    }

    .input-group input {
        font-size: 18px;
        padding: 16px;
    }

    .content-section h2 {
        font-size: 1.8rem;
    }
}

/* Animations */
@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.animate-fade {
    animation: fadeIn 0.6s ease forwards;
}

@keyframes pulse {

    0%,
    100% {
        box-shadow: 0 0 0 0 rgba(16, 185, 129, 0.4);
    }

    50% {
        box-shadow: 0 0 0 10px rgba(16, 185, 129, 0);
    }
}

.pulse {
    animation: pulse 2s infinite;
}

/* Toast Notification */
.toast {
    position: fixed;
    bottom: 30px;
    right: 30px;
    background: var(--success);
    color: white;
    padding: 16px 24px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    transform: translateY(100px);
    opacity: 0;
    transition: all 0.3s ease;
    z-index: 1000;
}

.toast.show {
    transform: translateY(0);
    opacity: 1;
}

/* Error State */
.input-group input.error {
    border-color: var(--danger);
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.1);
}

.error-message {
    color: var(--danger);
    font-size: 13px;
    margin-top: 8px;
    display: none;
}

.error-message.show {
    display: block;
}