* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #6366f1;
    --secondary-color: #ec4899;
    --dark-color: #1f2937;
    --light-color: #f3f4f6;
    --white-color: #ffffff;
    --text-color: #374151;
    --border-color: #e5e7eb;
    --success-color: #10b981;
    --warning-color: #f59e0b;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--light-color);
}

/* Advertisements */
.ad-container {
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 20px auto;
    max-width: 100%;
    min-height: 50px;
}

.ad-header {
    background-color: var(--white-color);
    padding: 15px 20px;
    border-bottom: 1px solid var(--border-color);
}

.ad-mid, .ad-side, .ad-lower {
    background-color: var(--white-color);
    padding: 20px;
    border-radius: 8px;
    margin: 30px auto;
    max-width: 728px;
}

/* Header & Navigation */
header {
    background-color: var(--white-color);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 100;
}

.navbar {
    padding: 0;
}

.nav-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 40px;
    max-width: 1200px;
    margin: 0 auto;
}

.logo h1 {
    color: var(--primary-color);
    font-size: 24px;
    font-weight: 700;
}

.nav-menu {
    display: flex;
    list-style: none;
    gap: 30px;
    align-items: center;
}

.nav-menu a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.nav-menu a:hover,
.nav-menu a.active {
    color: var(--primary-color);
}

.dropdown {
    position: relative;
}

.dropbtn {
    cursor: pointer;
}

.dropdown-content {
    display: none;
    position: absolute;
    background-color: var(--white-color);
    min-width: 200px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.2);
    padding: 12px 16px;
    z-index: 1;
    border-radius: 8px;
    top: 100%;
    left: 0;
}

.dropdown-content a {
    color: var(--text-color);
    padding: 12px 0;
    text-decoration: none;
    display: block;
    transition: color 0.3s ease;
}

.dropdown-content a:hover {
    color: var(--primary-color);
}

.dropdown:hover .dropdown-content {
    display: block;
}

.hamburger {
    display: none;
    flex-direction: column;
    cursor: pointer;
}

.hamburger span {
    width: 25px;
    height: 3px;
    background-color: var(--primary-color);
    margin: 5px 0;
    transition: 0.3s;
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--secondary-color) 100%);
    color: var(--white-color);
    padding: 80px 40px;
    text-align: center;
}

.hero-content h1 {
    font-size: 48px;
    margin-bottom: 20px;
    font-weight: 700;
}

.hero-content p {
    font-size: 18px;
    margin-bottom: 30px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

.cta-buttons {
    display: flex;
    gap: 20px;
    justify-content: center;
    flex-wrap: wrap;
}

.btn {
    padding: 12px 30px;
    border-radius: 50px;
    text-decoration: none;
    font-weight: 600;
    transition: all 0.3s ease;
    display: inline-block;
}

.btn-primary {
    background-color: var(--white-color);
    color: var(--primary-color);
}

.btn-primary:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

.btn-secondary {
    background-color: transparent;
    color: var(--white-color);
    border: 2px solid var(--white-color);
}

.btn-secondary:hover {
    background-color: var(--white-color);
    color: var(--primary-color);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 40px;
}

/* Tools Section */
.tools-section {
    padding: 80px 40px;
    background-color: var(--white-color);
}

.tools-section h2 {
    text-align: center;
    font-size: 36px;
    margin-bottom: 15px;
    color: var(--dark-color);
}

.section-subtitle {
    text-align: center;
    color: var(--text-color);
    margin-bottom: 50px;
    font-size: 16px;
}

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 30px;
}

.tool-card {
    background: var(--light-color);
    padding: 40px 30px;
    border-radius: 12px;
    text-align: center;
    transition: all 0.3s ease;
    border: 1px solid var(--border-color);
}

.tool-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.tool-icon {
    font-size: 48px;
    margin-bottom: 20px;
}

.tool-card h3 {
    font-size: 22px;
    margin-bottom: 15px;
    color: var(--dark-color);
}

.tool-card p {
    color: var(--text-color);
    margin-bottom: 20px;
    font-size: 14px;
}

.tool-link {
    color: var(--primary-color);
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.tool-link:hover {
    color: var(--secondary-color);
}

/* Features Section */
.features-section {
    padding: 80px 40px;
    background-color: var(--light-color);
}

.features-section h2 {
    text-align: center;
    font-size: 36px;
    margin-bottom: 50px;
    color: var(--dark-color);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 30px;
}

.feature {
    background: var(--white-color);
    padding: 30px;
    border-radius: 12px;
    border-left: 4px solid var(--primary-color);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.feature h4 {
    font-size: 18px;
    margin-bottom: 15px;
    color: var(--dark-color);
}

.feature p {
    color: var(--text-color);
    font-size: 14px;
}

/* Footer */
footer {
    background-color: var(--dark-color);
    color: var(--light-color);
    padding: 60px 40px 20px;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    max-width: 1200px;
    margin: 0 auto 40px;
}

.footer-section h4 {
    margin-bottom: 20px;
    color: var(--white-color);
}

.footer-section p {
    color: var(--light-color);
    font-size: 14px;
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
}

.footer-section ul li {
    margin-bottom: 12px;
}

.footer-section a {
    color: var(--light-color);
    text-decoration: none;
    transition: color 0.3s ease;
    font-size: 14px;
}

.footer-section a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    text-align: center;
    font-size: 14px;
    color: var(--light-color);
}

.footer-bottom a {
    color: var(--light-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-bottom a:hover {
    color: var(--primary-color);
}

/* Tool Pages Styling */
.tool-container {
    max-width: 900px;
    margin: 40px auto;
    padding: 0 40px;
}

.tool-page {
    background: var(--white-color);
    padding: 40px;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
}

.tool-page h1 {
    color: var(--dark-color);
    margin-bottom: 15px;
    font-size: 32px;
}

.tool-page > p {
    color: var(--text-color);
    margin-bottom: 30px;
    font-size: 16px;
}

.input-group {
    margin-bottom: 20px;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--dark-color);
}

.input-group input,
.input-group textarea,
.input-group select {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-family: inherit;
    font-size: 14px;
    transition: border-color 0.3s ease;
}

.input-group input:focus,
.input-group textarea:focus,
.input-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.1);
}

.tool-page textarea {
    resize: vertical;
    min-height: 150px;
}

.tool-buttons {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.tool-btn {
    padding: 12px 25px;
    background-color: var(--primary-color);
    color: var(--white-color);
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: all 0.3s ease;
    font-size: 14px;
}

.tool-btn:hover {
    background-color: #5558e3;
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(99, 102, 241, 0.3);
}

.tool-btn-secondary {
    background-color: var(--secondary-color);
}

.tool-btn-secondary:hover {
    background-color: #d91a72;
}

.output-box {
    background-color: var(--light-color);
    padding: 20px;
    border-radius: 8px;
    margin-top: 30px;
    border: 1px solid var(--border-color);
}

.output-box h3 {
    margin-bottom: 15px;
    color: var(--dark-color);
}

.output-box p,
.output-box pre {
    color: var(--text-color);
    background-color: var(--white-color);
    padding: 15px;
    border-radius: 6px;
    overflow-x: auto;
    font-size: 14px;
}

.success-message {
    background-color: #d1fae5;
    color: #065f46;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
    border-left: 4px solid var(--success-color);
}

.error-message {
    background-color: #fee2e2;
    color: #991b1b;
    padding: 12px;
    border-radius: 8px;
    margin-bottom: 15px;
    border-left: 4px solid #ef4444;
}

/* Responsive Design */
@media (max-width: 768px) {
    .nav-container {
        padding: 15px 20px;
        flex-wrap: wrap;
    }

    .nav-menu {
        gap: 15px;
        font-size: 14px;
    }

    .hamburger {
        display: flex;
    }

    .nav-menu {
        display: none;
        position: absolute;
        top: 70px;
        left: 0;
        background-color: var(--white-color);
        flex-direction: column;
        width: 100%;
        padding: 20px 0;
        box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
    }

    .nav-menu.active {
        display: flex;
    }

    .nav-menu li {
        padding: 10px 20px;
    }

    .dropdown-content {
        position: static;
        display: none;
        box-shadow: none;
        padding: 0;
    }

    .dropdown.active .dropdown-content {
        display: flex;
        flex-direction: column;
    }

    .hero-content h1 {
        font-size: 32px;
    }

    .hero-content p {
        font-size: 16px;
    }

    .cta-buttons {
        flex-direction: column;
        align-items: center;
    }

    .btn {
        width: 100%;
        max-width: 300px;
    }

    .container {
        padding: 0 20px;
    }

    .tools-section,
    .features-section {
        padding: 40px 20px;
    }

    .tools-section h2,
    .features-section h2 {
        font-size: 28px;
    }

    .tools-grid,
    .features-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }

    .tool-container {
        padding: 0 20px;
    }

    .tool-page {
        padding: 20px;
    }

    .tool-page h1 {
        font-size: 24px;
    }

    .tool-buttons {
        flex-direction: column;
    }

    .tool-btn {
        width: 100%;
    }

    .footer-content {
        grid-template-columns: 1fr;
        gap: 30px;
    }

    .ad-container {
        margin: 15px auto;
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .logo h1 {
        font-size: 18px;
    }

    .hero-content h1 {
        font-size: 24px;
    }

    .hero-content p {
        font-size: 14px;
    }

    .tools-section h2,
    .features-section h2 {
        font-size: 22px;
    }

    .tool-page h1 {
        font-size: 20px;
    }

    .section-subtitle {
        font-size: 14px;
    }
}
