/*** Root Variables ***/
:root {
    /* Primary Colors */
    --primary-color: #4A6FFF;
    --primary-color-light: rgba(74, 111, 255, 0.1);
    --primary-hover: #3D5CE5;
    --primary-active: #2A43B0;
    --primary-dim: rgba(0, 157, 255, 0.1);
    --primary-dark: #3367d6;
    
    /* Secondary & Accent Colors */
    --secondary-color: #FF6D4A;
    --accent-color: #4ADFFF;
    --danger-color: #ea4335;
    --error-color: #FF4A4A;
    --success-color: #4AFF91;
    --warning-color: #FFD44A;
    --info-color: #4ADFFF;
    
    /* Background Colors */
    --bg-dark: #000000;
    --bg-darker: #000000;
    --darker-bg: #000000; /* Added missing variable used in header */
    --card-bg: #181818;
    --card-bg-hover: #1a1a1a;
    --input-bg: #242424;
    --border-color: rgba(255, 255, 255, 0.1);
    
    /* Text Colors */
    --text-color: #e0e0e0;
    --text-bright: #ffffff;
    --text-light: #ffffff;
    --text-muted: rgba(255, 255, 255, 0.6);
    --text-gray: #888888;
    
    /* Effects */
    --card-shadow: 0 4px 20px rgba(0, 0, 0, 0.5);
    --shadow-color: rgba(0, 0, 0, 0.2);
    --glow-effect: 0 0 15px rgba(0, 157, 255, 0.6), 0 0 30px rgba(0, 157, 255, 0.3);
    --tech-gradient: linear-gradient(135deg, #009dff, #00b8ff, #00d4ff);
    
    /* Common Styling */
    --border-radius: 8px;
    --transition-speed: 0.3s;
    
    /* Fonts */
    --font-main: 'Roboto', sans-serif;

    /* New variables from the original code */
    --text-primary: #FFFFFF;
    --text-secondary: rgba(255, 255, 255, 0.8);
    --background-primary: #121212;
    --background-secondary: #1E1E1E;
    --background-tertiary: #252525;
    --background-card: rgba(255, 255, 255, 0.05);
    --background-hover: rgba(255, 255, 255, 0.1);
    --footer-bg: #0A0A0A;
    --footer-text: rgba(255, 255, 255, 0.7);
    --gradient-primary: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    --gradient-secondary: linear-gradient(135deg, var(--secondary-color), var(--primary-color));
    --gradient-accent: linear-gradient(135deg, var(--accent-color), var(--secondary-color));
    --container-width: 1200px;
    --card-border-radius: 12px;

    /* Tier variables */
    --tier-s: #FF4A4A;
    --tier-a: #FF8F4A;
    --tier-b: #FFD44A;
    --tier-c: #4AFF91;
    --tier-d: #4ADFFF;
    --tier-e: #4A6FFF;
    --tier-f: #9B4AFF;
}

/*** Reset and Base Styles ***/
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Roboto', system-ui, -apple-system, sans-serif;
}

/* Font Awesome icon fixes */
i.fas, i.far, i.fab, i.fa {
    display: inline-block !important;
    font-style: normal !important;
    font-variant: normal !important;
    font-family: "Font Awesome 5 Free", "Font Awesome 5 Brands" !important;
}

body {
    background-color: var(--bg-dark);
    color: var(--text-light);
    min-height: 100vh;
    line-height: 1.6;
    background-image: 
        radial-gradient(circle at 10% 20%, rgba(0, 157, 255, 0.03) 0%, transparent 30%),
        radial-gradient(circle at 90% 80%, rgba(0, 157, 255, 0.03) 0%, transparent 30%);
    position: relative;
    overflow-x: hidden;
}

body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: 
        linear-gradient(90deg, var(--bg-dark) 21px, transparent 1%) center,
        linear-gradient(var(--bg-dark) 21px, transparent 1%) center,
        rgba(0, 157, 255, 0.03);
    background-size: 22px 22px;
    z-index: -1;
    opacity: 0.4;
}

/*** Menu Button Styles ***/

.menu-button::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, var(--primary-color) 0%, transparent 70%);
    transform: translate(-50%, -50%) scale(0);
    opacity: 0;
    transition: transform 0.4s ease, opacity 0.4s ease;
}

.menu-button:hover::after {
    transform: translate(-50%, -50%) scale(2);
    opacity: 0.1;
}

.menu-button.active {
    background-color: var(--primary-dim);
    color: var(--primary-color);
}

/*** Header and Navigation ***/

.nav-link:hover::before,

/* Animation for nav overlay */

    
    
    
    /* Stagger animation for each link */
    .nav-links.active .nav-link:nth-child(1) { animation-delay: 0.1s; }
    .nav-links.active .nav-link:nth-child(2) { animation-delay: 0.2s; }
    .nav-links.active .nav-link:nth-child(3) { animation-delay: 0.3s; }
    .nav-links.active .nav-link:nth-child(4) { animation-delay: 0.4s; }
    .nav-links.active .nav-link:nth-child(5) { animation-delay: 0.5s; }
    
    
    
    /* Close button for mobile menu */
    .close-menu {
        position: absolute;
        top: 1rem;
        right: 1rem;
        background: none;
        border: none;
        color: var(--text-color);
        font-size: 1.5rem;
        cursor: pointer;
        z-index: 1003; /* Ensure it's above other elements */
    }
}

/* Animation for sliding in from right */
@keyframes fadeInRight {
    0% {
        opacity: 0;
        transform: translateX(20px);
    }
    100% {
        opacity: 1;
        transform: translateX(0);
    }
}

/*** Main Container ***/
.container {
    max-width: 1200px;
    margin: 2rem auto;
    padding: 2rem;
    background-color: var(--bg-darker);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5), 0 0 30px var(--shadow-color);
    border: 1px solid rgba(0, 157, 255, 0.1);
    position: relative;
    overflow: hidden;
    transition: transform 0.5s ease, box-shadow 0.5s ease;
}

.container::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 200%;
    height: 3px;
    background: var(--tech-gradient);
    animation: gradientBorder 6s linear infinite;
}

@keyframes gradientBorder {
    0% { transform: translateX(0); }
    100% { transform: translateX(50%); }
}

.container:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.6), 0 0 40px var(--shadow-color);
}

/*** Section Headers ***/
h1, h2 {
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    color: var(--primary-color);
    font-size: 2rem;
    text-shadow: 0 0 15px rgba(0, 157, 255, 0.4);
    position: relative;
}

h1::after, h2::after {
    content: '';
    position: absolute;
    bottom: -10px;
    left: 0;
    width: 60px;
    height: 3px;
    background: var(--tech-gradient);
    box-shadow: var(--glow-effect);
    transition: width 0.4s ease;
}

h1:hover::after, h2:hover::after {
    width: 120px;
}

/*** Form Elements ***/
.input-group {
    margin-bottom: 1.5rem;
    position: relative;
}

.input-wrapper {
    position: relative;
    display: flex;
    align-items: center;
}

.input-group label {
    display: block;
    margin-bottom: 0.75rem;
    color: var(--text-light);
    font-weight: 500;
    font-size: 1.1rem;
    transition: all 0.3s ease;
}

.input-group:hover label {
    color: var(--primary-color);
    transform: translateX(5px);
}

input {
    width: 100%;
    padding: 1rem 1.25rem;
    border: 2px solid transparent;
    border-radius: 8px;
    background-color: var(--input-bg);
    color: var(--text-light);
    font-size: 1rem;
    transition: all 0.4s ease;
    box-shadow: inset 0 0 10px rgba(0, 0, 0, 0.3);
}

input:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 15px var(--shadow-color), inset 0 0 10px rgba(0, 0, 0, 0.3);
    transform: scale(1.01);
}

.calculate-btn {
    width: 100%;
    padding: 1.25rem;
    background: var(--tech-gradient);
    border: none;
    border-radius: 8px;
    color: var(--text-light);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    transition: all 0.4s ease;
    margin-top: 2rem;
    position: relative;
    overflow: hidden;
    text-shadow: 0 0 10px rgba(255, 255, 255, 0.5);
    box-shadow: 0 5px 15px rgba(0, 157, 255, 0.3);
}

.calculate-btn::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.2);
    transform: skewX(-25deg);
    transition: all 0.6s ease;
}

.calculate-btn:hover::before {
    left: 100%;
}

.calculate-btn:hover {
    background: linear-gradient(135deg, #00b8ff, #00ff88, #00b8ff);
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(0, 157, 255, 0.4), 0 0 15px var(--shadow-color);
}

.calculate-btn:active {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(0, 157, 255, 0.3);
}

/*** Results Section ***/
#result {
    margin-top: 2.5rem;
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.result-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 2rem;
    margin-bottom: 2.5rem;
}

.result-item {
    background-color: var(--card-bg);
    padding: 2rem;
    border-radius: 12px;
    text-align: center;
    transition: all 0.4s ease;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    border: 1px solid rgba(0, 157, 255, 0.1);
    position: relative;
    overflow: hidden;
}

.result-item::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    z-index: -1;
    border-radius: 14px;
    background: var(--tech-gradient);
    opacity: 0;
    transition: opacity 0.4s ease;
}

.result-item:hover::before {
    opacity: 1;
}

.result-item:hover {
    transform: translateY(-10px) scale(1.02);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4), 0 0 15px var(--shadow-color);
}

.result-item .value {
    font-size: 2.5rem;
    color: var(--primary-color);
    font-weight: bold;
    margin-bottom: 0.75rem;
    text-shadow: 0 0 10px rgba(0, 157, 255, 0.4);
    transition: all 0.4s ease;
}

.result-item:hover .value {
    color: var(--primary-hover);
    text-shadow: 0 0 15px rgba(0, 255, 136, 0.6);
}

/*** Company Eligibility Section ***/
.eligibility-section {
    margin-top: 4rem;
    padding-top: 2rem;
    border-top: 1px solid rgba(0, 157, 255, 0.1);
    animation: fadeIn 0.8s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.tier-info {
    background-color: var(--card-bg);
    padding: 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(0, 157, 255, 0.1);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.tier-info::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 3px;
    background: var(--tech-gradient);
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.6s ease;
}

.tier-info:hover::after {
    transform: scaleX(1);
}

.tier-info:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.4), 0 0 20px var(--shadow-color);
}

.tier-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.tier-item {
    background-color: var(--bg-darker);
    padding: 1.5rem;
    border-radius: 8px;
    text-align: center;
    transition: all 0.4s ease;
    border: 1px solid rgba(0, 157, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.tier-item::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: var(--tech-gradient);
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
    z-index: -1;
}

.tier-item:hover {
    transform: translateY(-5px) scale(1.05);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.3), 0 0 15px var(--shadow-color);
    border-color: transparent;
}

.tier-item:hover::before {
    opacity: 0.1;
}

.tier-item h4 {
    color: var(--primary-color);
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
}

.tier-item:hover h4 {
    color: var(--primary-hover);
    text-shadow: 0 0 10px rgba(0, 255, 136, 0.4);
}

/*** Eligibility Results ***/
.eligibility-results {
    margin-top: 2rem;
    animation: fadeIn 1s ease;
}

.result-card {
    background-color: var(--card-bg);
    padding: 2rem;
    border-radius: 12px;
    margin-bottom: 2rem;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(0, 157, 255, 0.1);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.result-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 3px;
    height: 100%;
    background: var(--tech-gradient);
    transform: scaleY(0);
    transform-origin: top;
    transition: transform 0.6s ease;
}

.result-card:hover::before {
    transform: scaleY(1);
}

.result-card:hover {
    transform: translateX(5px);
    box-shadow: 0 5px 25px rgba(0, 0, 0, 0.4), 0 0 20px var(--shadow-color);
}

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

.stat-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 1.5rem;
    border-radius: 8px;
    background-color: rgba(0, 157, 255, 0.05);
    transition: all 0.4s ease;
    border: 1px solid rgba(0, 157, 255, 0.1);
}

.stat-item:hover {
    transform: translateY(-5px);
    background-color: rgba(0, 157, 255, 0.1);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2), 0 0 15px var(--shadow-color);
}

.stat-label {
    color: var(--text-gray);
    margin-bottom: 0.5rem;
    transition: all 0.3s ease;
}

.stat-item:hover .stat-label {
    color: var(--text-light);
}

.stat-value {
    font-size: 2rem;
    color: var(--primary-color);
    font-weight: bold;
    text-shadow: 0 0 10px rgba(0, 157, 255, 0.4);
    transition: all 0.3s ease;
}

.stat-item:hover .stat-value {
    color: var(--primary-hover);
    text-shadow: 0 0 15px rgba(0, 255, 136, 0.6);
    transform: scale(1.1);
}

/*** Tier Distribution ***/
.tier-distribution {
    margin-top: 2rem;
}

.tier-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.tier-stat {
    background-color: var(--bg-darker);
    padding: 1rem;
    border-radius: 8px;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    transition: all 0.4s ease;
    border: 1px solid rgba(0, 157, 255, 0.05);
    position: relative;
    overflow: hidden;
}

.tier-stat::after {
    content: '';
    position: absolute;
    width: 100%;
    height: 3px;
    background: var(--primary-color);
    bottom: 0;
    left: 0;
    transform: scaleX(0);
    transform-origin: left;
    transition: transform 0.4s ease, background 0.4s ease;
}

.tier-stat:hover::after {
    transform: scaleX(1);
    background: var(--primary-hover);
}

.tier-stat:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
    background-color: rgba(0, 157, 255, 0.05);
}

.tier-stat span:first-child {
    color: var(--text-gray);
    transition: all 0.3s ease;
}

.tier-stat:hover span:first-child {
    color: var(--text-light);
}

.tier-stat span:last-child {
    color: var(--primary-color);
    font-size: 1.5rem;
    font-weight: bold;
    transition: all 0.3s ease;
}

.tier-stat:hover span:last-child {
    color: var(--primary-hover);
    text-shadow: 0 0 10px rgba(0, 255, 136, 0.4);
    transform: scale(1.1);
}

/*** Charts Container ***/
.charts-container {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
    margin-top: 2.5rem;
}

.chart-wrapper {
    background-color: var(--card-bg);
    padding: 1.5rem;
    border-radius: 12px;
    min-height: 350px;
    box-shadow: 0 5px 20px rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(0, 157, 255, 0.1);
    transition: all 0.4s ease;
    position: relative;
    overflow: hidden;
}

.chart-wrapper::before {
    content: '';
    position: absolute;
    width: 100%;
    height: 100%;
    background: 
        radial-gradient(circle at 20% 30%, rgba(0, 157, 255, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 70%, rgba(0, 255, 136, 0.05) 0%, transparent 50%);
    top: 0;
    left: 0;
    opacity: 0;
    transition: opacity 0.4s ease;
}

.chart-wrapper:hover::before {
    opacity: 1;
}

.chart-wrapper:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4), 0 0 20px var(--shadow-color);
}

/*** Error Messages ***/
#error {
    display: none;
    color: var(--error-color);
    background-color: rgba(255, 68, 68, 0.1);
    padding: 1rem 1.5rem;
    border-radius: 8px;
    margin: 1.5rem 0;
    text-align: center;
    font-weight: 500;
    animation: shake 0.5s ease;
    border-left: 3px solid var(--error-color);
    position: relative;
    overflow: hidden;
}

#error::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(45deg, transparent, rgba(255, 68, 68, 0.05), transparent);
    animation: errorGlow 2s infinite;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    10%, 30%, 50%, 70%, 90% { transform: translateX(-5px); }
    20%, 40%, 60%, 80% { transform: translateX(5px); }
}

/*** Media Queries ***/
@media screen and (max-width: 768px) {
    html, body {
        overflow-x: hidden;
    }
    
    body {
        position: relative;
        width: 100%;
    }
    
    .cgpa-calculator {
        padding: 15px;
    }
    
    .results-container {
        flex-direction: column;
    }
    
    .semester-results, .overall-results {
        width: 100%;
        margin: 10px 0;
    }
    
    .course-list {
        overflow-x: auto;
    }
    
    .course-row {
        grid-template-columns: 2fr 1fr 1fr;
    }
    
    .course-actions {
        grid-column: span 3;
        display: flex;
        justify-content: flex-end;
        margin-top: 10px;
    }
    
    .options-container {
        flex-wrap: wrap;
    }
    
    .footer-content {
        flex-direction: column;
    }
}

.footer {
    position: relative;
    background-color: var(--footer-bg);
    color: var(--text-light);
    padding: 3rem 1.5rem 1.5rem;
    margin-top: 4rem;
}

.footer-content {
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    max-width: 1200px;
    margin: 0 auto;
    gap: 2rem;
}

.footer-section h3 {
    color: var(--primary-color);
    font-size: 1.3rem;
    margin-bottom: 15px;
    position: relative;
    display: inline-block;
}

.footer-section h3::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 40px;
    height: 2px;
    background-color: var(--primary-color);
}

.footer-section p {
    margin: 10px 0;
    transition: transform 0.3s ease;
    line-height: 1.6;
}

.footer-section p:hover {
    transform: translateY(-2px);
}

.tagline {
    font-style: italic;
    color: #888888;
    font-size: 0.9rem;
    margin-top: 5px;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 10px;
}

.footer-section ul li a {
    color: var(--text-gray);
    text-decoration: none;
    transition: all 0.3s ease;
    position: relative;
    padding-left: 15px;
}

.footer-section ul li a::before {
    content: '›';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    transition: transform 0.3s ease;
}

.footer-section ul li a:hover {
    color: var(--text-light);
    padding-left: 20px;
}

.footer-section ul li a:hover::before {
    transform: translateX(3px);
}

.feedback-link {
    display: inline-block;
    color: var(--primary-color);
    text-decoration: none;
    padding: 8px 16px;
    border-radius: 20px;
    border: 2px solid var(--primary-color);
    transition: all 0.3s ease;
    background: transparent;
    position: relative;
    overflow: hidden;
    margin-top: 10px;
}

.feedback-link:hover {
    color: var(--text-light);
    background: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0, 157, 255, 0.2);
}

.feedback-link::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.feedback-link:active::before {
    width: 200px;
    height: 200px;
}

.footer-bottom {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(160, 160, 160, 0.2);
}

.developer-name {
    font-weight: 500;
    color: #b8b8b8;
    transition: all 0.3s ease;
}

.developer-name:hover {
    color: var(--text-light);
    text-shadow: 0 0 8px rgba(255, 255, 255, 0.3);
}

.social-links {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.social-link {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background-color: rgba(0, 157, 255, 0.1);
    color: var(--primary-color);
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-link:hover {
    background-color: var(--primary-color);
    color: var(--text-light);
    transform: translateY(-3px);
    box-shadow: 0 4px 10px rgba(0, 157, 255, 0.3);
}

/*** Related Tools Section ***/
/* Related Tools Section */
.related-tools {
    margin-bottom: 3rem;
    padding-top: 6rem; /* Adds space at the top */
}

.tools-container {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    max-width: 1000px;
    margin: 0 auto;
    width: 100%;
}

.tool-card {
    text-decoration: none;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    padding: 1.8rem;
    box-shadow: var(--card-shadow);
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    transition: transform var(--transition-speed) ease, 
                box-shadow var(--transition-speed) ease, 
                background-color var(--transition-speed) ease;
    color: var(--text-color);
    position: relative;
    overflow: hidden;
    z-index: 1;
    border: 1px solid var(--border-color);
    height: 100%;
}

.tool-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 5px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    transition: height var(--transition-speed) ease;
    z-index: -1;
}

.tool-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 12px 25px rgba(0, 0, 0, 0.15);
    background-color: var(--card-bg-hover);
}

.tool-card:hover::before {
    height: 100%;
    opacity: 0.1;
}

.tool-card i {
    font-size: 2.5rem;
    color: var(--primary-color);
    margin-bottom: 1.2rem;
    transition: transform var(--transition-speed) ease, 
                color var(--transition-speed) ease;
}

.tool-card:hover i {
    transform: scale(1.2);
    color: var(--secondary-color);
}

.tool-card h3 {
    margin-bottom: 0.8rem;
    color: var(--text-bright);
    font-weight: 600;
}

.tool-card p {
    color: var(--text-muted);
    line-height: 1.5;
    margin-top: 0.5rem;
}

/* Responsive adjustments */
@media (max-width: 1024px) {
    .tools-container {
        max-width: 100%;
        padding: 0 1.5rem;
    }
}

@media (max-width: 768px) {
    .tools-container {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .footer-section h3::after {
        left: 50%;
        transform: translateX(-50%);
    }
    
    .footer-section ul li a {
        padding-left: 0;
    }
    
    .footer-section ul li a::before {
        display: none;
    }
    
    .social-links {
        justify-content: center;
    }
}

/* Accessibility improvements */
@media (prefers-reduced-motion: reduce) {
    .tool-card, 
    .tool-card::before,
    .tool-card i,
    .footer::before,
    .footer-section p,
    .feedback-link,
    .footer-section ul li a,
    .footer-section ul li a::before,
    .social-link {
        transition: none;
        transform: none;
        animation: none;
    }
    
    .tool-card:hover,
    .tool-card:hover i {
        transform: none;
    }
}

/* Custom Scrollbar - Make it smaller and minimal */
::-webkit-scrollbar {
    width: 3px;
    height: 3px;
}

::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.02);
    border-radius: 2px;
}

::-webkit-scrollbar-thumb {
    background: var(--primary-color);
    border-radius: 2px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-hover);
}

/* Firefox scrollbar */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--primary-color) rgba(0, 0, 0, 0.02);
}
