:root {
    --primary-color: #2563eb;
    --primary-hover: #1d4ed8;
    --bg-color: #ffffff;
    --secondary-bg: #f8fafc;
    --text-main: #1e293b;
    --text-muted: #64748b;
    --border-color: #e2e8f0;
    --card-shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1);
    --transition: all 0.3s ease;
    --container-width: 1200px;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    line-height: 1.6;
    color: var(--text-main);
    background-color: var(--bg-color);
}

.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1.5rem;
}

/* Header Styles */
header {
    background: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(10px);
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 0;
    z-index: 1000;
}

nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 70px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
}

.logo img {
    height: 32px;
    border-radius: 8px;
    /* Squircle-like rounded corners */
    object-fit: cover;
}

.nav-links {
    display: flex;
    gap: 2rem;
    list-style: none;
}

.nav-links a {
    text-decoration: none;
    color: var(--text-main);
    font-weight: 500;
    transition: var(--transition);
}

.nav-links a:hover {
    color: var(--primary-color);
}

/* Footer Styles */
footer {
    background: #020617;
    /* Dark background */
    color: #9ca3af;
    padding: 4rem 0 2rem;
    margin-top: 4rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 3rem;
    margin-bottom: 3rem;
}

.footer-col h3 {
    margin-bottom: 1.5rem;
    font-size: 1.1rem;
    color: #ffffff;
    /* White headings */
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.75rem;
}

.footer-links a {
    text-decoration: none;
    color: #9ca3af;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #ffffff;
}

.footer-bottom {
    text-align: center;
    padding-top: 2rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    color: #64748b;
    font-size: 0.9rem;
}

.footer-bottom a {
    color: #3b82f6;
    text-decoration: none;
}



/* Hero Section */
.hero {
    padding: 6rem 0;
    text-align: center;
    background: linear-gradient(135deg, #f8fafc 0%, #ffffff 100%);
}

.hero h1 {
    font-size: 3rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: var(--text-main);
    line-height: 1.2;
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-muted);
    max-width: 800px;
    margin: 0 auto 2.5rem;
}

.hero-btns {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

.btn {
    padding: 0.75rem 2rem;
    border-radius: 8px;
    font-weight: 600;
    text-decoration: none;
    transition: var(--transition);
    cursor: pointer;
    display: inline-block;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: var(--primary-hover);
}

.btn-outline {
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
}

.btn-outline:hover {
    background: var(--primary-color);
    color: white;
}

/* Calculator Grid */
.calculator-grid-section {
    padding: 4rem 0;
}

/* Category Groups */
.category-group {
    margin-bottom: 4rem;
}

.category-title {
    font-size: 1.5rem;
    color: var(--text-main);
    margin-bottom: 2rem;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid var(--primary-color);
    display: inline-block;
}

.calculator-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 1.5rem;
}

/* Benefits Section */
.benefits {
    padding: 6rem 0;
    background: var(--secondary-bg);
}

.benefits h2 {
    text-align: center;
    margin-bottom: 4rem;
}

.benefits-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

/* Cookie Banner */
.cookie-banner {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #1e293b;
    color: white;
    padding: 1rem 0;
    z-index: 2000;
}

.cookie-banner .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
}

.cookie-banner button {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.5rem 1.5rem;
    border-radius: 4px;
    cursor: pointer;
}

/* Page Layouts */
.page-hero {
    background: var(--primary-color);
    color: white;
    padding: 4rem 0;
    text-align: center;
}

.page-hero h1 {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.content-section {
    padding: 4rem 0;
}

.text-content {
    max-width: 800px;
    margin: 0 auto;
}

.text-content h2 {
    margin: 2.5rem 0 1rem;
}

.text-content p {
    margin-bottom: 1.5rem;
}

.calc-card {
    background: white;
    padding: 2rem;
    border-radius: 12px;
    border: 1px solid var(--border-color);
    transition: var(--transition);
    text-decoration: none;
    color: inherit;
    display: block;
}

.calc-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--card-shadow);
    border-color: var(--primary-color);
}

.calc-icon {
    font-size: 2.5rem;
    margin-bottom: 1rem;
}

.calc-card h3 {
    font-size: 1.25rem;
    margin-bottom: 0.75rem;
}

.calc-card p {
    color: var(--text-muted);
    font-size: 1rem;
}

.btn-text {
    color: var(--primary-color);
    font-weight: 600;
    text-decoration: none;
    margin-top: 1rem;
    display: inline-block;
}

/* Calculator Specific Styles */
.calc-container {
    max-width: 600px;
    margin: 2rem auto;
    background: white;
    padding: 2rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: var(--card-shadow);
}

/* Form Styles for Calculators */
.calc-form {
    display: grid;
    gap: 1.5rem;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.input-group label {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text-main);
}

.input-group input,
.input-group select {
    padding: 0.75rem;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
}

.result-card {
    background: #eff6ff;
    padding: 1.5rem;
    border-radius: 12px;
    margin-top: 2rem;
    text-align: center;
}

.result-title {
    font-size: 0.9rem;
    color: var(--text-muted);
    margin-bottom: 0.5rem;
}

.result-value {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
}

/* Special Grid for Basic/Scientific */
.display-area {
    background: #f1f5f9;
    padding: 1.5rem;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    text-align: right;
    min-height: 100px;
}

.calc-buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 0.5rem;
}

.calc-buttons.scientific {
    grid-template-columns: repeat(5, 1fr);
}

.calc-btn {
    padding: 1rem;
    border: none;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    background: #f8fafc;
}

.calc-btn:hover {
    background: #e2e8f0;
}

.calc-btn.op {
    color: var(--primary-color);
}

.calc-btn.eq {
    background: var(--primary-color);
    color: white;
    grid-column: span 2;
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2.25rem;
    }

    .hero-btns {
        flex-direction: column;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .nav-links {
        display: none;
    }
}

/* Premium Content Page Utilities */
.page-hero {
    background: linear-gradient(135deg, #2563eb 0%, #1d4ed8 100%);
    color: white;
    padding: 6rem 0;
    text-align: center;
}

.content-section {
    padding: 5rem 0;
}

.policy-block {
    margin-bottom: 3rem;
    padding: 2.5rem;
    background: #ffffff;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    box-shadow: 0 10px 30px -5px rgba(0, 0, 0, 0.05);
    transition: all 0.3s ease;
}

.policy-block:hover {
    transform: translateY(-5px);
    box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.1);
}

.policy-block h2 {
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.8rem;
    font-weight: 700;
}

.contact-center {
    text-align: center;
    max-width: 800px;
    margin: 0 auto;
}

.contact-card {
    background: white;
    padding: 4rem;
    border-radius: 32px;
    border: 1px solid var(--border-color);
    box-shadow: 0 30px 60px -12px rgba(0, 0, 0, 0.15);
    margin-top: 4rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2rem;
}

.contact-icon {
    font-size: 4rem;
    background: #eff6ff;
    width: 100px;
    height: 100px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--primary-color);
    box-shadow: inset 0 2px 4px rgba(0, 0, 0, 0.05);
}

.email-link {
    font-size: 2rem;
    font-weight: 800;
    color: var(--primary-color);
    text-decoration: none;
    transition: opacity 0.3s ease;
}

.email-link:hover {
    opacity: 0.8;
}

.text-content ul {
    margin: 2rem 0;
    padding-left: 2rem;
    list-style: none;
}

.text-content li {
    margin-bottom: 1.2rem;
    position: relative;
    padding-left: 2rem;
    font-size: 1.1rem;
}

.text-content li::before {
    content: "⚡";
    position: absolute;
    left: 0;
    color: var(--primary-color);
}

.feature-list {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 2rem;
    margin-top: 4rem;
}

.feature-item {
    padding: 2.5rem;
    background: white;
    border-radius: 20px;
    border: 1px solid var(--border-color);
    border-top: 6px solid var(--primary-color);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    transition: transform 0.3s ease;
}

.feature-item:hover {
    transform: scale(1.02);
}

.feature-item h3 {
    margin-bottom: 1rem;
    color: #0f172a;
}