:root {
    --primary-color: #F97316;
    /* Orange 500 */
    --primary-hover: #EA580C;
    /* Orange 600 */
    --secondary-color: #FFF7ED;
    /* Orange 50 */
    --background-color: #FFF7ED;
    /* Unified background color */
    --card-bg: #FFFFFF;
    --text-primary: #1F2937;
    --text-secondary: #6B7280;
    --border-color: #CBD5E1;
    --danger-color: #EF4444;
    --dark-bg: #1A1A1A;
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
    --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);
    --radius: 12px;
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: var(--font-family);
    background-color: var(--background-color);
    color: var(--text-primary);
    line-height: 1.6;
    padding: 0;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    overflow-x: hidden;
}

html {
    overflow-x: hidden;
}

img {
    max-width: 100%;
    height: auto;
}

/* Navbar */
.navbar {
    background-color: var(--dark-bg);
    padding: 0.5rem 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.nav-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
    color: white;
}

.nav-logo-img {
    width: min(380px, 85vw); /* Responsive width: up to 380px but scales down automatically */
    height: auto;
    display: block;
    margin-left: -35px;   /* Generalized Desktop margin: prevents clipping on smaller desktops */
    margin-top: -45px;    /* Trims top whitespace in image */
    margin-bottom: -50px; /* Trims bottom whitespace in image */
    object-fit: contain;
}

/* Tablet Responsiveness (481px - 1024px) */
@media (max-width: 1024px) {
    .nav-logo-img {
        width: 320px;     /* Professional tablet scale */
        margin-left: -20px; /* Safe margin for tablets: no edge cutting */
        margin-top: -40px;
        margin-bottom: -45px;
    }
}

/* Mobile Responsiveness (below 480px) */
@media (max-width: 480px) {
    .nav-logo-img {
        width: 250px;     /* Consistent mobile scale */
        margin-left: -15px; /* Safest margin for phones: ensures full visibility */
        margin-top: -35px;
        margin-bottom: -45px;
    }
}

.footer-logo-img {
    width: 280px;         /* Increased width for direct control */
    height: auto;
    display: block;
    margin-left: -20px;   /* Safe Desktop margin: prevents edge crowding */
    margin-top: -30px;    /* Trims top whitespace in image */
    margin-bottom: -30px; /* Trims bottom whitespace in image */
    object-fit: contain;
}

/* Tablet Responsiveness for Footer Logo */
@media (max-width: 1024px) {
    .footer-logo-img {
        width: 260px;     /* Balanced tablet scale */
        margin-left: -15px; /* Safe tablet margin: no edge cutting */
        margin-top: -25px;
        margin-bottom: -30px;
    }
}

/* Mobile Responsiveness for Footer Logo */
@media (max-width: 480px) {
    .footer-logo-img {
        width: 220px;     /* Consistent mobile footer scale */
        margin-left: -10px; /* Safest margin for phones: ensures full visibility */
        margin-top: -20px;
        margin-bottom: -35px;
    }
}

.nav-text h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin: 0;
}

.nav-links {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    color: #E5E7EB;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.95rem;
    transition: color 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.nav-link.active-link {
    background: var(--primary-color);
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
}

.nav-link:hover {
    color: var(--primary-color);
}

.nav-link.active-link:hover {
    color: white;
    background: var(--primary-hover);
}

/* Nav Toggle */
.nav-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.nav-toggle span {
    width: 100%;
    height: 3px;
    background-color: white;
    border-radius: 10px;
    transition: all 0.3s linear;
    position: relative;
    transform-origin: 1px;
}

/* Hero Section */
.hero {
    padding: 1.5rem 20px;
    /* Reduced from 4rem */
    background: #FFF7ED;
    /* Noticeable light orange tint (Orange 50) */
    text-align: center;
}

.hero-badge {
    background: var(--secondary-color);
    color: var(--primary-color);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 1.5rem;
}

.hero h1 {
    font-size: 2.25rem;
    /* Slightly smaller */
    font-weight: 800;
    color: #111;
    margin-bottom: 0.5rem;
    /* Reduced from 1rem */
    line-height: 1.2;
}

.hero p {
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 3rem;
    font-size: 1.1rem;
}

.hero-icon {
    background: #111;
    color: white;
    width: 48px;
    height: 48px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    font-size: 1.5rem;
}

/* Calculator Container Wrapper */
.calculator-container-new {
    max-width: 900px;
    margin: 0 auto;
    background: #FFFFFF;
    border-radius: 16px;
    box-shadow: var(--shadow-lg);
    padding: 0.75rem;
    /* Reduced from 1rem */
    border: 2px solid #111111;
    /* Bolder, darker border */
}

.calculator-tabs {
    display: flex;
    gap: 10px;
    background: #F3F4F6;
    padding: 6px;
    /* Reduced from 8px */
    border-radius: 12px;
    margin-bottom: 1rem;
    /* Reduced from 2rem */
}

.tab-btn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: transparent;
    color: var(--text-secondary);
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
}

.tab-btn.active {
    background: var(--primary-color);
    color: white;
    box-shadow: var(--shadow-md);
}

.tab-content {
    display: none;
}

.tab-content.active {
    display: block;
}

.calc-title {
    text-align: center;
    color: var(--primary-color);
    margin-bottom: 0.75rem;
    /* Reduced from 1rem */
    font-size: 1.25rem;
    font-weight: 800;
}

.row-headers {
    display: grid;
    grid-template-columns: 0.8fr 1.6fr 1.6fr 40px;
    gap: 10px;
    padding: 0 10px 10px 0;
    font-weight: 800;
    color: var(--text-primary);
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.row-headers span {
    display: flex;
    align-items: center;
    justify-content: center;
    text-align: center;
}

.row-headers.cgpa-headers {
    grid-template-columns: 0.8fr 1.6fr 1.6fr 40px;
}

.calc-rows-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 0.75rem;
    /* Reduced from 1rem */
    max-height: 220px;
    /* Reduced from 250px */
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 10px;
}

/* Scrollbar Styling */
.calc-rows-container::-webkit-scrollbar {
    width: 6px;
}

.calc-rows-container::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.calc-rows-container::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 10px;
}

.calc-row {
    display: grid;
    grid-template-columns: 0.8fr 1.6fr 1.6fr 40px;
    gap: 10px;
    align-items: center;
}

.row-label {
    font-weight: 600;
    color: var(--text-primary);
    background: #f8fafc;
    padding: 8px 10px;
    /* Reduced vertical padding */
    border-radius: 8px;
    border: 1.5px solid var(--border-color);
    font-size: 0.85rem;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calc-row.semester-row {
    grid-template-columns: 0.8fr 1.6fr 1.6fr 40px;
}

.calc-row input,
.calc-row select {
    padding: 8px 10px;
    /* Reduced vertical padding */
    border: 1.5px solid var(--border-color);
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    transition: border-color 0.2s;
    text-align: center;
}

.calc-row input::placeholder {
    text-align: center;
    font-weight: 600;
}

.calc-row input:focus,
.calc-row select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1);
}

.remove-row-btn {
    background: var(--danger-color);
    color: white;
    border: none;
    width: 40px;
    height: 40px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s;
}



.remove-row-btn:hover {
    opacity: 0.9;
}

.calc-controls {
    display: flex;
    gap: 15px;
    margin-bottom: 1rem;
    /* Reduced from 2rem */
}

.btn-add-row {
    flex: 1;
    background: #FFFFFF;
    border: 2px solid var(--primary-color);
    color: var(--primary-color);
    padding: 12px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-add-row:hover {
    background: var(--secondary-color);
}


.btn-reset {
    flex: 1;
    background: #FFF7ED;
    border: none;
    color: #EA580C;
    padding: 12px;
    border-radius: 10px;
    font-weight: 600;
    cursor: pointer;
}

.result-placeholder {
    background: #F0FDF4;
    /* Light success green for placeholder */
    color: #166534;
    padding: 15px;
    border-radius: 10px;
    text-align: center;
    font-weight: 700;
    font-size: 1.1rem;
    border: 1px solid #BBF7D0;
}

.result-value {
    font-size: 2.5rem;
    color: var(--primary-color);
    display: block;
    margin-top: 10px;
}

/* Process Section */
.section-process {
    padding: 4rem 20px;
    background: var(--background-color);
    text-align: center;
}

.section-badge {
    background: #FFF3E0;
    color: var(--primary-color);
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 1.5rem;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    color: #111;
    margin-bottom: 1rem;
}

.section-desc {
    color: var(--text-secondary);
    max-width: 600px;
    margin: 0 auto 3rem;
}

.process-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1.5rem;
    max-width: 1200px;
    margin: 0 auto;
}

.process-grid-btm {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    max-width: 800px;
    margin: 1.5rem auto 0;
}

.process-card {
    background: white;
    padding: 2rem;
    border-radius: var(--radius);
    text-align: left;
    box-shadow: var(--shadow-sm);
    transition: transform 0.2s;
    position: relative;
    border: 1px solid white;
}

.process-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
    border-color: var(--border-color);
}

.step-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.step-num {
    font-size: 2rem;
    font-weight: 700;
    color: #E5E7EB;
}

.step-icon {
    width: 40px;
    height: 40px;
    background: #F3F4F6;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text-secondary);
}

.process-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #111;
}

.process-card p {
    font-size: 0.9rem;
    color: var(--text-secondary);
    line-height: 1.6;
}

/* System Info Section */
.section-info {
    padding: 4rem 20px;
    text-align: center;
    background: var(--background-color);
}

.info-badge {
    background: #111;
    color: white;
    padding: 6px 16px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 1.5rem;
}

/* Features & Tech Section */
.section-features {
    padding: 4rem 20px;
    background: var(--background-color);
}

.features-container {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: start;
}

.features-left {
    padding-right: 2rem;
}

.feature-title-group {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 2rem;
}

.feature-icon-lg {
    width: 40px;
    height: 40px;
    background: #FFF3E0;
    color: var(--primary-color);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.25rem;
}

.features-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.feature-item {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 0.95rem;
    color: var(--text-secondary);
}

.check-icon {
    color: #10B981;
    /* Green for check */
    background: #ECFDF5;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    flex-shrink: 0;
}

.tech-card {
    background: #1F1F1F;
    border-radius: 16px;
    padding: 2.5rem;
    color: white;
}

.tech-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 2rem;
}

.tech-icon-main {
    width: 32px;
    height: 32px;
    background: var(--primary-color);
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.tech-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.tech-item {
    background: rgba(255, 255, 255, 0.05);
    padding: 1rem;
    border-radius: 8px;
    display: flex;
    gap: 1rem;
    align-items: flex-start;
}

.tech-item-icon {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    flex-shrink: 0;
}

.tech-content h4 {
    font-size: 0.95rem;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.tech-content p {
    font-size: 0.8rem;
    color: #9CA3AF;
    line-height: 1.4;
}

/* Footer (Updated) */
.site-footer {
    background-color: var(--dark-bg);
    color: #E5E7EB;
    padding: 4rem 20px 2rem;
    font-size: 0.95rem;
}

.footer-content {
    max-width: 1200px;
    margin: 0 auto;
}

.footer-top-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 3rem;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    color: white;
    text-decoration: none;
}

.footer-logo .nav-icon {
    background: var(--primary-color);
}

.footer-links-row {
    display: flex;
    gap: 2rem;
}

.footer-link {
    color: #9CA3AF;
    text-decoration: none;
    font-size: 0.9rem;
    transition: color 0.2s;
}

.footer-link:hover {
    color: white;
}

.footer-btm {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #6B7280;
    font-size: 0.85rem;
}

.footer-socials {
    display: flex;
    gap: 1rem;
}

.social-btn {
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: background 0.2s;
}

.social-btn:hover {
    background: rgba(255, 255, 255, 0.2);
}

/* -----------------------------------------------------------
   Legacy Calculator Styles (Preserved & Adapted) 
----------------------------------------------------------- */


/* Semester Card Styles */
.semester-card {
    background: var(--card-bg);
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    border: 1px solid var(--border-color);
    transition: box-shadow 0.2s;
}

.semester-card:hover {
    box-shadow: var(--shadow-md);
}

.semester-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.5rem;
    border-bottom: 1px solid var(--border-color);
}

.semester-title {
    color: #111;
    font-size: 1.2rem;
    font-weight: 700;
}

.remove-semester-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0 0.5rem;
    transition: color 0.2s;
}

.remove-semester-btn:hover {
    color: var(--danger-color);
}

/* Course List Styles */
.course-header-row {
    gap: 10px;
    padding: 0.75rem 0.5rem;
    background-color: var(--secondary-color);
    /* Orange Tint */
    border-radius: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--primary-color);
    align-items: center;
}

.course-row {
    gap: 10px;
    align-items: center;
}

.course-name {
    font-weight: 500;
    color: #111;
    display: block;
    padding: 0.5rem;
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 0.6rem;
    border: 1px solid var(--border-color);
    border-radius: 6px;
    font-family: inherit;
    font-size: 0.95rem;
    transition: border-color 0.2s;
    background: #fff;
}

.input-group input:focus,
.input-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(249, 115, 22, 0.1);
}

.remove-course-btn {
    background: none;
    border: none;
    color: #9CA3AF;
    font-size: 1.25rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: color 0.2s;
}

.remove-course-btn:hover {
    color: var(--danger-color);
}

.semester-footer {
    margin-top: 1.5rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.add-course-btn {
    background: none;
    border: 1px dashed var(--primary-color);
    color: var(--primary-color);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.2s;
    font-size: 0.9rem;
}

.add-course-btn:hover {
    background: var(--secondary-color);
    border-style: solid;
}

.semester-result {
    font-size: 1.1rem;
    color: var(--text-primary);
}

/* Controls Section */
.controls {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-top: 2rem;
}

.action-buttons {
    display: flex;
    gap: 1rem;
}

.btn {
    padding: 0.85rem 1.5rem;
    border-radius: var(--radius);
    border: none;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s;
    text-align: center;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.btn-secondary {
    background-color: white;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
    width: 100%;
}

.btn-secondary:hover {
    background-color: var(--secondary-color);
}

.btn-primary {
    background-color: var(--primary-color);
    color: white;
    flex: 2;
    box-shadow: var(--shadow-md);
}

.btn-primary:hover {
    background-color: var(--primary-hover);
    transform: translateY(-2px);
    box-shadow: var(--shadow-lg);
}

.btn-outline {
    background: white;
    border: 2px solid var(--border-color);
    color: var(--text-secondary);
    flex: 1;
}

.btn-outline:hover {
    border-color: var(--text-primary);
    color: var(--text-primary);
    background: #F9FAFB;
}

/* Results Section */
.results-section {
    margin-top: 2rem;
    animation: slideUp 0.3s ease-out;
}

.results-section.hidden {
    display: none;
}

.result-card {
    background: #111;
    /* Dark bg for result like screenshot features */
    color: white;
    padding: 2.5rem;
    border-radius: var(--radius);
    text-align: center;
    box-shadow: var(--shadow-lg);
}

.result-card h2 {
    font-size: 1.25rem;
    opacity: 0.8;
    margin-bottom: 0.5rem;
    font-weight: 500;
}

.cgpa-value {
    font-size: 4.5rem;
    font-weight: 800;
    line-height: 1;
    margin-bottom: 2rem;
    background: linear-gradient(135deg, #fff, #fb923c);
    -webkit-background-clip: text;
    background-clip: text;
    -webkit-text-fill-color: transparent;
}

.stats {
    display: flex;
    justify-content: space-around;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 2rem;
}

.stat-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-item .label {
    font-size: 0.8rem;
    opacity: 0.6;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stat-item .value {
    font-size: 1.4rem;
    font-weight: 700;
}

/* Responsive */
@media (max-width: 900px) {
    .process-grid {
        grid-template-columns: 1fr;
    }

    .process-grid-btm {
        grid-template-columns: 1fr;
    }

    .features-container {
        grid-template-columns: 1fr;
    }

    .features-left {
        padding-right: 0;
        margin-bottom: 2rem;
    }
}

@media (max-width: 1024px) {

    .hero {
        padding: 1rem 4px;
    }

    .hero h1 {
        font-size: 1.8rem;
    }

    .calculator-container-new {
        padding: 4px;
        margin-left: 0;
        margin-right: 0;
    }

    .hero p {
        font-size: 1rem;
    }

    .section-title {
        font-size: 1.5rem;
    }

    .nav-links {
        gap: 0.5rem;
    }

    .nav-link {
        font-size: 0.85rem;
        padding: 5px 10px !important;
    }

    .row-headers {
        display: none;
    }

    .calc-row {
        grid-template-columns: 76px 1fr 0.8fr 35px;
        gap: 4px;
    }

    .calc-row.semester-row {
        grid-template-columns: 76px 1fr 0.8fr 35px;
        gap: 4px;
    }

    .row-label {
        font-size: 0.7rem;
        padding: 6px 2px;
        min-width: 0;
    }

    .calc-row input,
    .calc-row select {
        font-size: 0.9rem;
        padding: 8px 4px;
        min-width: 0;
    }

    .remove-row-btn {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }

    .course-header-row,
    .course-row {
        grid-template-columns: 76px 1fr 0.8fr 35px;
        gap: 4px;
    }

    .calc-rows-container {
        padding-right: 0;
    }

    .course-name {
        font-size: 0.9rem;
    }

    .stats {
        flex-direction: column;
        gap: 1.5rem;
    }

    .controls,
    .action-buttons {
        flex-direction: column;
    }

    .footer-top-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 2rem;
    }

    .footer-links-row {
        flex-direction: column;
        gap: 1rem;
    }

    /* Semantic Grid Mobile */
    .semantic-grid {
        grid-template-columns: 1fr !important;
        gap: 2rem !important;
    }

    .semantic-image {
        order: -1;
    }

    /* Process Grid Mobile */
    .process-grid {
        grid-template-columns: 1fr;
    }

    /* Result Display Mobile - Unified */

    /* Converter Widget Mobile Padding */
    .converter-widget {
        padding: 1.5rem !important;
    }

    /* HEC Banner Mobile */
    .hec-banner-mobile {
        max-width: 100% !important;
    }

    /* Navbar Mobile Dropdown */
    .nav-toggle {
        display: flex;
    }

    .nav-links {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        width: 100%;
        background: var(--dark-bg);
        flex-direction: column;
        padding: 1.5rem;
        gap: 1rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
        box-shadow: var(--shadow-md);
        z-index: 1000;
        animation: slideDown 0.3s ease-out;
    }

    .nav-links.active {
        display: flex;
    }

    .nav-link {
        width: 100%;
        justify-content: center;
        padding: 10px !important;
    }

    .nav-link.active-link {
        border-radius: 8px;
    }

    /* Hamburger Animation */
    .nav-toggle.open span:nth-child(1) {
        transform: rotate(45deg);
    }

    .nav-toggle.open span:nth-child(2) {
        opacity: 0;
    }

    .nav-toggle.open span:nth-child(3) {
        transform: rotate(-45deg);
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Scroll Top Button - Restored */
.scroll-top-btn {
    position: fixed;
    bottom: 20px;
    right: 20px;
    background-color: var(--primary-color);
    color: white;
    border: none;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.5rem;
    box-shadow: var(--shadow-md);
    display: none;
    z-index: 1000;
    transition: transform 0.2s, background-color 0.2s;
    align-items: center;
    justify-content: center;
    padding: 0;
    line-height: 1;
}

.scroll-top-btn:hover {
    transform: translateY(-4px);
    background-color: var(--primary-hover);
    box-shadow: var(--shadow-lg);
}

/* Grading Scheme Table */
.grading-table-container {
    overflow-x: auto;
    background: white;
    border-radius: var(--radius);
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    margin-top: 2rem;
}

.grading-table {
    width: 100%;
    border-collapse: collapse;
    text-align: left;
    min-width: 600px;
}

.grading-table th,
.grading-table td {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.grading-table th {
    background-color: var(--secondary-color);
    color: var(--primary-color);
    font-weight: 700;
    font-size: 0.95rem;
}

.grading-table td {
    font-size: 0.9rem;
    color: var(--text-primary);
}

.grading-table tr:last-child td {
    border-bottom: none;
}

.grading-table tr:hover {
    background-color: #FAFAFA;
}

/* Redesigned Features Section */
.new-features-section {
    padding: 6rem 20px;
    background: #FFF7ED;
}

.features-header-centered {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 4rem;
}

.features-top-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    max-width: 1000px;
    margin: 0 auto 5rem;
}

.feature-pill {
    background: white;
    padding: 1.5rem;
    border-radius: 12px;
    display: flex;
    align-items: center;
    gap: 1rem;
    border: 1px solid var(--border-color);
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.feature-pill:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.feature-icon-box {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: var(--secondary-color);
    color: var(--primary-color);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 800;
    flex-shrink: 0;
}

.feature-text {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 1rem;
    line-height: 1.4;
}

/* Technical Accuracy Grid */
.tech-section-title {
    text-align: center;
    font-size: 2rem;
    font-weight: 800;
    margin-bottom: 3rem;
    color: #111;
}

.tech-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 1100px;
    margin: 0 auto;
}

.tech-card-modern {
    background: #1A1A1A;
    border-radius: 16px;
    padding: 2.5rem;
    color: white;
    text-align: left;
    transition: transform 0.3s ease;
    position: relative;
    overflow: hidden;
    border: 1px solid #333;
}

.tech-card-modern:hover {
    transform: translateY(-8px);
    border-color: var(--primary-color);
}

.tech-card-icon {
    width: 48px;
    height: 48px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
    font-size: 1.5rem;
}

.tech-card-modern h4 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 1rem;
    color: white;
}

.tech-card-modern p {
    color: #9CA3AF;
    line-height: 1.6;
    font-size: 0.95rem;
}

@media (max-width: 900px) {

    .features-top-grid,
    .tech-grid-3 {
        grid-template-columns: 1fr;
    }
}


/* Universal Compatibility Section (Light Theme) */
.section-compatibility {
    padding: 6rem 20px;
    background: #FFF7ED;
    color: var(--text-primary);
    position: relative;
    overflow: hidden;
}

.compatibility-content {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
    z-index: 2;
}

.comp-header {
    text-align: center;
    max-width: 800px;
    margin: 0 auto 4rem;
}

.comp-badge {
    background: #FFF7ED;
    color: var(--primary-color);
    border: 1px solid rgba(249, 115, 22, 0.2);
    padding: 8px 16px;
    border-radius: 30px;
    font-size: 0.85rem;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 1.5rem;
}

.comp-title {
    font-size: 2.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: #111;
}

.comp-desc {
    color: var(--text-secondary);
    font-size: 1.1rem;
    line-height: 1.7;
}

.comp-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    margin-bottom: 4rem;
}

.comp-card {
    background: white;
    border: 1px solid var(--border-color);
    padding: 2rem;
    border-radius: 16px;
    transition: all 0.3s ease;
    box-shadow: var(--shadow-sm);
}

.comp-card:hover {
    transform: translateY(-5px);
    border-color: var(--primary-color);
    box-shadow: var(--shadow-md);
}

.comp-icon {
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, var(--primary-color), #EA580C);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    margin-bottom: 1.5rem;
    box-shadow: 0 4px 10px rgba(249, 115, 22, 0.3);
}

.comp-card h3 {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    color: #111;
}

.comp-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

/* University Ticker/Grid */
.uni-trust-section {
    border-top: 1px solid var(--border-color);
    padding-top: 3rem;
    text-align: center;
}

.uni-title {
    font-size: 0.9rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-secondary);
    margin-bottom: 2rem;
}

.uni-tags {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
}

.uni-tag {
    background: white;
    color: var(--text-secondary);
    padding: 8px 20px;
    border-radius: 30px;
    font-size: 0.9rem;
    font-weight: 500;
    border: 1px solid var(--border-color);
    transition: all 0.2s;
}

.uni-tag:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
    background: #FFF7ED;
}

@media (max-width: 900px) {
    .comp-grid {
        grid-template-columns: 1fr;
    }

    .comp-title {
        font-size: 2rem;
    }
}

/* FAQ Section */
.section-faq {
    padding: 6rem 20px;
    background: #FFF7ED;
    position: relative;
    border-top: 1px solid var(--border-color);
}

.faq-container {
    max-width: 1000px;
    margin: 0 auto;
}

.faq-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
}

@media (max-width: 768px) {
    .faq-grid {
        grid-template-columns: 1fr;
    }
}

.faq-header {
    text-align: center;
    margin-bottom: 4rem;
}

.faq-title {
    font-size: 2.5rem;
    font-weight: 800;
    color: #111;
    margin-bottom: 1rem;
}

.faq-desc {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

.faq-item {
    background: white;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    margin-bottom: 1rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    border-color: var(--primary-color);
    box-shadow: var(--shadow-sm);
}

.faq-item details {
    padding: 1.5rem;
    cursor: pointer;
}

.faq-item summary {
    font-weight: 700;
    font-size: 1.1rem;
    color: #111;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.faq-item summary::-webkit-details-marker {
    display: none;
}

.faq-item summary::after {
    content: '+';
    font-size: 1.5rem;
    font-weight: 400;
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.faq-item details[open] summary::after {
    transform: rotate(45deg);
}

.faq-answer {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid var(--border-color);
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
    animation: slideDown 0.3s ease-out;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* -----------------------------------------------------------
   Cookie Notice Styles
----------------------------------------------------------- */
.cookie-notice {
    position: fixed;
    bottom: 20px;
    left: 20px;
    right: 20px;
    background: #111;
    color: white;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    z-index: 9999;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 1rem;
    transform: translateY(150%);
    transition: transform 0.3s ease-out;
    max-width: 1200px;
    margin: 0 auto;
}

.cookie-notice.show {
    transform: translateY(0);
}

.cookie-content {
    font-size: 0.9rem;
    color: #E5E7EB;
}

.cookie-content a {
    color: var(--primary-color);
    text-decoration: none;
}

.cookie-content a:hover {
    text-decoration: underline;
}

.cookie-btn-accept {
    background: var(--primary-color);
    color: white;
    border: none;
    padding: 0.5rem 1.5rem;
    border-radius: 6px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s;
    white-space: nowrap;
}

.cookie-btn-accept:hover {
    background: var(--primary-hover);
}

@media (max-width: 768px) {
    .cookie-notice {
        flex-direction: column;
        text-align: center;
        bottom: 0;
        left: 0;
        right: 0;
        border-radius: 12px 12px 0 0;
        padding-bottom: 2rem;
    }
}

/* -----------------------------------------------------------
   Achievement Section Styles
----------------------------------------------------------- */
.section-achievement {
    padding: 6rem 20px;
    background: #FFF7ED;
}

.achievement-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 4rem;
}

.achievement-content {
    flex: 1;
}

.achievement-image {
    flex: 1;
    position: relative;
}

.achievement-image img {
    width: 100%;
    height: auto;
    border-radius: 24px;
    box-shadow: var(--shadow-lg);
    transition: transform 0.3s ease;
}

.achievement-image:hover img {
    transform: scale(1.02);
}

.achievement-features {
    margin-top: 2.5rem;
    display: grid;
    gap: 1.5rem;
}

.achieve-feat-item {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
}

.achieve-feat-icon {
    font-size: 1.5rem;
    background: var(--secondary-color);
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    flex-shrink: 0;
}

.achieve-feat-item h4 {
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
    color: #111;
}

.achieve-feat-item p {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

@media (max-width: 900px) {
    .achievement-container {
        flex-direction: column;
        text-align: center;
        gap: 3rem;
    }

    .achievement-content .section-title,
    .achievement-content .section-desc {
        text-align: center !important;
        margin: 0 auto 1.5rem !important;
    }

    .achieve-feat-item {
        flex-direction: column;
        align-items: center;
    }
}

/* SEO Section Redesign Styles */
.section-seo-redesign {
    background: #FFF7ED;
    border-top: 1px solid var(--border-color);
}

.seo-feature-card {
    background: white;
    padding: 1.5rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    transition: all 0.3s ease;
}

.seo-feature-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.seo-image-container {
    transition: transform 0.5s ease;
}

.seo-image-container:hover {
    transform: scale(1.02) rotate(1deg);
}

@media (max-width: 900px) {
    .seo-main-grid {
        grid-template-columns: 1fr !important;
        gap: 3rem !important;
    }

    .seo-text-col {
        order: 1;
        text-align: center;
    }

    .seo-image-col {
        order: 2;
    }

    .seo-features-grid {
        grid-template-columns: 1fr !important;
    }
}

/* Semantic SEO Content Styles */
.section-semantic {
    padding: 6rem 20px;
    background: #FFF7ED;
}

.semantic-grid {
    max-width: 1200px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.semantic-content h2 {
    font-size: 2.25rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: #111;
}

.semantic-content p {
    color: var(--text-secondary);
    margin-bottom: 1.25rem;
    font-size: 1.05rem;
    line-height: 1.8;
}

.comparison-box {
    background: var(--background-color);
    border-radius: 20px;
    padding: 2.5rem;
    border: 1px solid var(--border-color);
}

.comp-item {
    margin-bottom: 2rem;
}

.comp-item:last-child {
    margin-bottom: 0;
}

.comp-tag {
    display: inline-block;
    padding: 4px 12px;
    background: var(--primary-color);
    color: white;
    border-radius: 8px;
    font-size: 0.8rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
}

.comp-item h4 {
    font-size: 1.25rem;
    margin-bottom: 0.5rem;
    color: #111;
}

.comp-item p {
    font-size: 0.95rem;
    color: var(--text-secondary);
}

/* Modern Conversion Section Styles */
.conversion-container-modern {
    background: #FFFFFF;
    border: 1px solid var(--border-color);
    padding: 3.5rem;
    border-radius: 32px;
    margin-top: 2.5rem;
    box-shadow: var(--shadow-sm);
}

.conversion-ui-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
    align-items: center;
    text-align: left;
    margin-bottom: 4rem;
}

.converter-widget {
    background: #111827;
    /* Dark Slate */
    padding: 2.5rem;
    border-radius: 24px;
    color: white;
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
}

.converter-widget h4 {
    font-size: 1.25rem;
    margin-bottom: 2rem;
    color: #F97316;
    /* primary-color */
    font-weight: 700;
}

.converter-input-group label {
    display: block;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 0.75rem;
    color: #9CA3AF;
}

.converter-input-group input {
    width: 100%;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.25rem;
    border-radius: 12px;
    color: white;
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 2rem;
    transition: all 0.2s ease;
}

.converter-input-group input:focus {
    outline: none;
    border-color: #F97316;
    background: rgba(255, 255, 255, 0.08);
}

.converter-result-box {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 1.5rem;
}

.res-label {
    font-size: 0.85rem;
    color: #9CA3AF;
    display: block;
    margin-bottom: 0.5rem;
}

.res-value {
    font-size: 3rem;
    font-weight: 800;
    color: #10B981;
    /* Success Green */
    line-height: 1;
}

.formula-info-box h3 {
    font-size: 1.75rem;
    margin-bottom: 1.25rem;
    color: #111;
}

.formula-box-premium {
    background: #F3F4F6;
    padding: 1rem 1.5rem;
    border-radius: 12px;
    border-left: 4px solid #F97316;
    margin-bottom: 1.5rem;
}

.formula-box-premium code {
    font-family: 'JetBrains Mono', monospace;
    font-size: 1.1rem;
    color: #111;
    font-weight: 600;
}

.formula-note {
    font-size: 0.95rem;
    color: var(--text-secondary);
    line-height: 1.7;
}

.chart-header {
    margin-bottom: 2rem;
    text-align: center;
}

.chart-badge {
    display: inline-block;
    padding: 4px 12px;
    background: #ECFDF5;
    color: #10B981;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 700;
    margin-bottom: 0.75rem;
    text-transform: uppercase;
}

.chart-img-premium {
    width: 100%;
    max-width: 900px;
    border-radius: 24px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.15);
    border: 1px solid rgba(0, 0, 0, 0.05);
    margin: 0 auto;
    display: block;
}

.chart-footer-text {
    margin-top: 1.5rem;
    font-size: 0.9rem;
    color: var(--text-secondary);
    font-style: italic;
}

@media (max-width: 900px) {
    .conversion-ui-grid {
        grid-template-columns: 1fr;
        gap: 2.5rem;
    }

    .conversion-container-modern {
        padding: 2rem 1.5rem;
    }

    .res-value {
        font-size: 2.5rem;
    }
}

.benefit-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    margin-top: 2rem;
}

.benefit-card {
    background: white;
    padding: 1.5rem;
    border-radius: 16px;
    border: 1px solid var(--border-color);
    display: flex;
    gap: 1rem;
    transition: all 0.2s ease;
}

.benefit-card:hover {
    border-color: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.benefit-icon {
    font-size: 1.5rem;
    flex-shrink: 0;
}

.benefit-info h4 {
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: #111;
}

.benefit-info p {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

@media (max-width: 900px) {
    .semantic-grid {
        grid-template-columns: 1fr;
        gap: 3rem;
    }

    .benefit-grid {
        grid-template-columns: 1fr;
    }

    .section-semantic {
        padding: 4rem 20px;
    }
}

/* SEO Micro-Section Styles */

/* 1. Manual Formula Box */
.manual-formula-box {
    margin-top: 1.5rem;
    padding: 1.25rem;
    background: #f8fafc;
    border-left: 4px solid var(--primary-color);
    border-radius: 8px;
    box-shadow: var(--shadow-sm);
}

.formula-title {
    font-weight: 700;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
    color: #111;
}

.formula-text {
    display: block;
    font-family: 'Courier New', Courier, monospace;
    font-weight: 800;
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    font-size: 1rem;
}

.formula-footer {
    font-size: 0.8rem;
    color: var(--text-secondary);
    font-style: italic;
}

/* 2. Quick Calculation Methods Accordion */
.quick-accordion {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.quick-item {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.quick-item[open] {
    box-shadow: var(--shadow-md);
    border-color: var(--primary-color);
}

.quick-item summary {
    padding: 1.25rem;
    font-weight: 600;
    color: #111;
    cursor: pointer;
    list-style: none;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s;
}

.quick-item summary::after {
    content: '+';
    font-size: 1.25rem;
    font-weight: 400;
    color: var(--primary-color);
}

.quick-item[open] summary::after {
    content: '−';
}

.quick-item summary:hover {
    background: var(--secondary-color);
}

.quick-content {
    padding: 0 1.25rem 1.25rem;
    color: var(--text-secondary);
    font-size: 0.95rem;
    line-height: 1.6;
}

.quick-content code {
    display: block;
    margin-top: 0.75rem;
    padding: 0.75rem;
    background: #f1f5f9;
    border-radius: 6px;
    color: #111;
    font-family: inherit;
    font-weight: 600;
}

/* 3. Mini Examples Section */
.mini-examples-list {
    margin-top: 2rem;
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.example-item {
    padding-bottom: 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.example-item:last-child {
    border-bottom: none;
}

.example-item strong {
    display: block;
    font-size: 1rem;
    color: #111;
    margin-bottom: 0.5rem;
}

.example-item p {
    font-size: 0.95rem;
    color: var(--text-secondary);
    margin: 0;
}

/* =========================================
   NEW STYLES: Related Tools Grid
   ========================================= */

.tools-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 2rem;
    padding: 1rem 0;
}

.tool-card {
    background: #FFFFFF;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05);
    /* Soft shadow */
    text-align: center;
    text-decoration: none;
    color: inherit;
    transition: all 0.3s ease;
    border: 1px solid #F3F4F6;
    display: flex;
    flex-direction: column;
    align-items: center;
    height: 100%;
}

.tool-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 15px -3px rgba(0, 0, 0, 0.1);
    border-color: var(--primary-color);
}

.tool-icon-box {
    width: 64px;
    height: 64px;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    transition: transform 0.3s;
}

.tool-card:hover .tool-icon-box {
    transform: scale(1.1);
}

.tool-card h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #1F2937;
}

/* =========================================
   NEW STYLES: Relevant Tools Internal Linking Bar
   ========================================= */

.tools-nav-container {
    max-width: 1000px;
    margin: 3rem auto 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 1.5rem;
    flex-wrap: wrap;
    padding: 0 1rem;
}

.tools-nav-label {
    font-size: 1.1rem;
    font-weight: 700;
    color: #111;
    white-space: nowrap;
}

.tool-pill-link {
    background: #FFFFFF;
    color: var(--text-primary);
    padding: 0.75rem 1.5rem;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 0.95rem;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    transition: all 0.2s ease;
    border: 1px solid rgba(0, 0, 0, 0.05);
    display: inline-block;
}

.tool-pill-link:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
    color: var(--primary-color);
    border-color: rgba(249, 115, 22, 0.2);
}

@media (max-width: 768px) {
    .tools-nav-container {
        flex-direction: column;
        gap: 1rem;
        margin-top: 2.5rem;
    }

    .tool-pill-link {
        width: 100%;
        text-align: center;
    }
}

/* University Specific Calculator Grid - Compact Premium Design */
.section-uni-calculators {
    background: linear-gradient(180deg, #ffffff 0%, #FFF7ED 100%);
    padding: 4rem 20px !important;
}

.uni-calc-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    /* 4 columns for a more compact look */
    gap: 1rem;
    margin-top: 3rem;
}

.uni-calc-card {
    background: #FFFFFF;
    border: 1px solid rgba(226, 232, 240, 0.8);
    border-radius: 14px;
    padding: 0.85rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    text-decoration: none;
    color: #1E293B;
    position: relative;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.02);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
}

.uni-calc-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(249, 115, 22, 0.04) 0%, transparent 100%);
    opacity: 0;
    transition: opacity 0.3s ease;
}

.uni-calc-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 12px 20px -5px rgba(0, 0, 0, 0.05);
    border-color: var(--primary-color);
}

.uni-calc-card:hover::before {
    opacity: 1;
}

.uni-calc-card span {
    font-weight: 600;
    font-size: 0.95rem;
    flex-grow: 1;
    transition: color 0.3s ease;
    position: relative;
    z-index: 2;
    line-height: 1.2;
}

.uni-calc-card .arrow-icon {
    width: 24px;
    height: 24px;
    color: #CBD5E1;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
}

.uni-calc-card:hover .arrow-icon {
    transform: translateX(3px);
    color: var(--primary-color);
}

@media (max-width: 1200px) {
    .uni-calc-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 900px) {
    .uni-calc-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 500px) {
    .uni-calc-grid {
        grid-template-columns: 1fr;
    }
}

/* Contact Grid */
.contact-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    margin-bottom: 2rem;
}

@media (max-width: 900px) {
    .contact-grid {
        grid-template-columns: 1fr;
    }
}