/* =========================================
   1. GLOBAL BADGE & FLAG STYLES
   ========================================= */

/* =========================================
   GLOBAL COUNTRY FLAG
   ========================================= */

.country-flag-img {
    width: 64px;                 /* Mobile default */
    height: auto;                
    display: block;
    margin: 0 auto 1.5rem;

    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    border: 1px solid rgba(0,0,0,0.06);
    transition: transform 0.3s ease;
}

/* Larger on tablets and desktops */
@media (min-width: 768px) {
    .country-flag-img {
        width: 80px;             /* Bigger on larger screens */
    }
}

.country-flag-img:hover {
    transform: translateY(-3px);
}



/* The Country Name Box (Badge) */
.country-badge {
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
    background-color: #ffffff !important;
    border: 3px solid; /* Color comes from Theme */
    border-radius: 12px !important; 
    padding: 0.8rem 2.5rem !important;
    
    font-weight: 900 !important;
    text-transform: uppercase;
    font-size: 2rem !important; 
    letter-spacing: 1px;
    
    width: auto !important;
    cursor: default;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}



/* =========================================
   2. GLOBAL TILE INTERACTIONS (Clean Shadow Only)
   ========================================= */

/* Base Style */
.stat-box, 
.why-card, 
.requirement-card {
    background-color: #ffffff;
    transition: box-shadow 0.3s ease; /* Only animate shadow */
    border: 1px solid #f3f4f6; /* Very subtle grey border for definition */
    cursor: default;
    height: 100%;
}

/* HOVER EFFECT: Simple Glow (No Border Color, No Raising) */
.stat-box:hover, 
.why-card:hover, 
.requirement-card:hover {
    transform: none !important; /* Ensures it stays flat */
    border-color: #f3f4f6; /* Keeps border neutral */
    box-shadow: 0 12px 40px rgba(0,0,0,0.12); /* The "Simple Hover" Effect */
}

/* =========================================
   3. THEME COLORS (Headings & Badges & Icons)
   ========================================= */

/* --- AUSTRALIA (Deep Blue) --- */
.theme-australia h1 { color: #00008B !important; }
.theme-australia .country-badge { 
    color: #00008B !important; 
    border-color: #00008B !important; 
}
.theme-australia .why-card .why-card-icon { 
    color: #00008B !important; 
}

/* --- CANADA (Red) --- */
.theme-canada h1 { color: #d80621 !important; }
.theme-canada .country-badge { 
    color: #d80621 !important; 
    border-color: #d80621 !important; 
}
.theme-canada .why-card .why-card-icon { 
    color: #d80621 !important; 
}

/* --- DENMARK (Red) --- */
.theme-denmark h1 { color: #C60C30 !important; }
.theme-denmark .country-badge { 
    color: #C60C30 !important; 
    border-color: #C60C30 !important; 
}
.theme-denmark .why-card .why-card-icon { 
    color: #C60C30 !important; 
}

/* --- FRANCE (Blue) --- */
.theme-france h1 { color: #0055A4 !important; }
.theme-france .country-badge { 
    color: #0055A4 !important; 
    border-color: #0055A4 !important; 
}
.theme-france .why-card .why-card-icon { 
    color: #0055A4 !important; 
}

/* --- GERMANY (Black-Red-Gold - Using Black) --- */
.theme-germany h1 { color: #000000 !important; }
.theme-germany .country-badge { 
    color: #000000 !important; 
    border-color: #000000 !important; 
}
.theme-germany .why-card .why-card-icon { 
    color: #DD0000 !important; /* Red for contrast */
}

/* --- IRELAND (Green) --- */
.theme-ireland h1 { color: #169B62 !important; }
.theme-ireland .country-badge { 
    color: #169B62 !important; 
    border-color: #169B62 !important; 
}
.theme-ireland .why-card .why-card-icon { 
    color: #169B62 !important; 
}

/* --- ITALY (Green) --- */
.theme-italy h1 { color: #009246 !important; }
.theme-italy .country-badge { 
    color: #009246 !important; 
    border-color: #009246 !important; 
}
.theme-italy .why-card .why-card-icon { 
    color: #009246 !important; 
}

/* --- NETHERLANDS (Orange) --- */
.theme-netherlands h1 { color: #FF6C00 !important; }
.theme-netherlands .country-badge { 
    color: #FF6C00 !important; 
    border-color: #FF6C00 !important; 
}
.theme-netherlands .why-card .why-card-icon { 
    color: #FF6C00 !important; 
}

/* --- NEW ZEALAND (Black) --- */
.theme-new-zealand h1 { color: #000000 !important; }
.theme-new-zealand .country-badge { 
    color: #000000 !important; 
    border-color: #000000 !important; 
}
.theme-new-zealand .why-card .why-card-icon { 
    color: #00247D !important; /* Navy Blue for contrast */
}

/* --- SINGAPORE (Red) --- */
.theme-singapore h1 { color: #EF3340 !important; }
.theme-singapore .country-badge { 
    color: #EF3340 !important; 
    border-color: #EF3340 !important; 
}
.theme-singapore .why-card .why-card-icon { 
    color: #EF3340 !important; 
}

/* --- SPAIN (Red & Gold - Using Red) --- */
.theme-spain h1 { color: #C60B1E !important; }
.theme-spain .country-badge { 
    color: #C60B1E !important; 
    border-color: #C60B1E !important; 
}
.theme-spain .why-card .why-card-icon { 
    color: #C60B1E !important; 
}

/* --- SWEDEN (Blue & Yellow - Using Blue) --- */
.theme-sweden h1 { color: #006AA7 !important; }
.theme-sweden .country-badge { 
    color: #006AA7 !important; 
    border-color: #006AA7 !important; 
}
.theme-sweden .why-card .why-card-icon { 
    color: #FECC00 !important; /* Yellow for contrast */
}

/* --- SWITZERLAND (Red) --- */
.theme-switzerland h1 { color: #FF0000 !important; }
.theme-switzerland .country-badge { 
    color: #FF0000 !important; 
    border-color: #FF0000 !important; 
}
.theme-switzerland .why-card .why-card-icon { 
    color: #FF0000 !important; 
}

/* --- UK (Navy Blue) --- */
.theme-uk h1 { color: #00247D !important; }
.theme-uk .country-badge { 
    color: #00247D !important; 
    border-color: #00247D !important; 
}
.theme-uk .why-card .why-card-icon { 
    color: #CF142B !important; /* Red for contrast */
}

/* --- USA (Navy Blue & Red - Using Navy) --- */
.theme-usa h1 { color: #3C3B6E !important; }
.theme-usa .country-badge { 
    color: #3C3B6E !important; 
    border-color: #3C3B6E !important; 
}
.theme-usa .why-card .why-card-icon { 
    color: #B22234 !important; /* Red for contrast */
}

/* =========================================
   4. UNIVERSITY BRAND COLORS (Grouped by Country)
   ========================================= */

/* --- AUSTRALIA (Group of 8) --- */
.uni-melb { color: #094183; font-weight: bold; margin-bottom: 0.5rem; }
.uni-syd  { color: #E1462C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-unsw { color: #D4AF37; font-weight: bold; margin-bottom: 0.5rem; }
.uni-anu  { color: #BE830E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-uq   { color: #49075E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-monash { color: #0063A6; font-weight: bold; margin-bottom: 0.5rem; }
.uni-uwa  { color: #27348B; font-weight: bold; margin-bottom: 0.5rem; }
.uni-adelaide { color: #102535; font-weight: bold; margin-bottom: 0.5rem; }

/* --- CANADA --- */
.uni-toronto { color: #002A5C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-mcgill { color: #ED1B2F; font-weight: bold; margin-bottom: 0.5rem; }
.uni-ubc { color: #002145; font-weight: bold; margin-bottom: 0.5rem; }
.uni-waterloo { color: #d4a017; font-weight: bold; margin-bottom: 0.5rem; }
.uni-alberta { color: #007C41; font-weight: bold; margin-bottom: 0.5rem; }
.uni-mcmaster { color: #7A003C; font-weight: bold; margin-bottom: 0.5rem; }

/* --- DENMARK --- */
.uni-cph { color: #901A1E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-dtu { color: #990000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-aarhus { color: #002546; font-weight: bold; margin-bottom: 0.5rem; }
.uni-aalborg { color: #2F3E4E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-cbs { color: #4B2D83; font-weight: bold; margin-bottom: 0.5rem; }
.uni-sdu { color: #000000; font-weight: bold; margin-bottom: 0.5rem; }

/* --- USA (Top Tier) --- */
.uni-harvard { color: #A51C30; font-weight: bold; margin-bottom: 0.5rem; }
.uni-mit { color: #A31F34; font-weight: bold; margin-bottom: 0.5rem; }
.uni-stanford { color: #8C1515; font-weight: bold; margin-bottom: 0.5rem; }
.uni-caltech { color: #FF6C0C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-uchicago { color: #800000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-upenn { color: #011F5B; font-weight: bold; margin-bottom: 0.5rem; }

/* --- UNITED KINGDOM (Russell Group) --- */
.uni-oxford { color: #002147; font-weight: bold; margin-bottom: 0.5rem; }
.uni-cambridge { color: #A3C1AD; font-weight: bold; margin-bottom: 0.5rem; }
.uni-imperial { color: #003E74; font-weight: bold; margin-bottom: 0.5rem; }
.uni-ucl { color: #500778; font-weight: bold; margin-bottom: 0.5rem; }
.uni-edinburgh { color: #D50032; font-weight: bold; margin-bottom: 0.5rem; }
.uni-manchester { color: #660099; font-weight: bold; margin-bottom: 0.5rem; }
.uni-kcl { color: #E30613; font-weight: bold; margin-bottom: 0.5rem; }
.uni-lse { color: #E03C31; font-weight: bold; margin-bottom: 0.5rem; }

/* --- GERMANY (TU9 & Excellence) --- */
.uni-tum { color: #3070B3; font-weight: bold; margin-bottom: 0.5rem; }
.uni-lmu { color: #00883A; font-weight: bold; margin-bottom: 0.5rem; }
.uni-rwth { color: #00549F; font-weight: bold; margin-bottom: 0.5rem; }
.uni-heidelberg { color: #990000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-tuberlin { color: #C50E1F; font-weight: bold; margin-bottom: 0.5rem; }
.uni-kit { color: #009682; font-weight: bold; margin-bottom: 0.5rem; }
.uni-humboldt { color: #00376C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-stuttgart { color: #004191; font-weight: bold; margin-bottom: 0.5rem; }
.uni-dresden { color: #002557; font-weight: bold; margin-bottom: 0.5rem; }

/* --- FRANCE (Grandes Écoles & Unis) --- */
.uni-psl { color: #000000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-polytech { color: #D4AF37; font-weight: bold; margin-bottom: 0.5rem; }
.uni-sorbonne { color: #1D2342; font-weight: bold; margin-bottom: 0.5rem; }
.uni-saclay { color: #7F1455; font-weight: bold; margin-bottom: 0.5rem; }
.uni-hec { color: #433D62; font-weight: bold; margin-bottom: 0.5rem; }
.uni-insead { color: #006847; font-weight: bold; margin-bottom: 0.5rem; }
.uni-sciencespo { color: #E30613; font-weight: bold; margin-bottom: 0.5rem; }
.uni-essec { color: #004E7C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-grenoble { color: #0087CD; font-weight: bold; margin-bottom: 0.5rem; }

/* --- NETHERLANDS (Research Unis) --- */
.uni-tudelft { color: #00A6D6; font-weight: bold; margin-bottom: 0.5rem; }
.uni-amsterdam { color: #1F1D21; font-weight: bold; margin-bottom: 0.5rem; }
.uni-wageningen { color: #34B44A; font-weight: bold; margin-bottom: 0.5rem; }
.uni-leiden { color: #001158; font-weight: bold; margin-bottom: 0.5rem; }
.uni-erasmus { color: #002A5C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-utrecht { color: #FFCD00; font-weight: bold; margin-bottom: 0.5rem; }
.uni-groningen { color: #DC002E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-tue { color: #D60036; font-weight: bold; margin-bottom: 0.5rem; }
.uni-maastricht { color: #00305E; font-weight: bold; margin-bottom: 0.5rem; }

/* --- SWEDEN (Nordic Excellence) --- */
.uni-karolinska { color: #87003E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-lund { color: #00205B; font-weight: bold; margin-bottom: 0.5rem; }
.uni-kth { color: #1954A6; font-weight: bold; margin-bottom: 0.5rem; }
.uni-uppsala { color: #990000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-stockholm { color: #002F5F; font-weight: bold; margin-bottom: 0.5rem; }
.uni-chalmers { color: #000000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-gothenburg { color: #004B87; font-weight: bold; margin-bottom: 0.5rem; }
.uni-linkoping { color: #00B5E2; font-weight: bold; margin-bottom: 0.5rem; }
.uni-jonkoping { color: #E3000F; font-weight: bold; margin-bottom: 0.5rem; }

/* --- SWITZERLAND (Federal & Cantonal) --- */
.uni-eth { color: #1F407A; font-weight: bold; margin-bottom: 0.5rem; }
.uni-epfl { color: #FF0000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-zurich { color: #0028A5; font-weight: bold; margin-bottom: 0.5rem; }
.uni-geneva { color: #C5003E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-stgallen { color: #004E35; font-weight: bold; margin-bottom: 0.5rem; }
.uni-bern { color: #E6002E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-basel { color: #D2002E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-lausanne { color: #008799; font-weight: bold; margin-bottom: 0.5rem; }
.uni-usi { color: #FFCC00; font-weight: bold; margin-bottom: 0.5rem; }

/* --- IRELAND --- */
.uni-tcd { color: #005697; font-weight: bold; margin-bottom: 0.5rem; }
.uni-ucd { color: #00467F; font-weight: bold; margin-bottom: 0.5rem; }
.uni-galway { color: #9D1E1E; font-weight: bold; margin-bottom: 0.5rem; }
.uni-ucc { color: #CE1F2C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-dcu { color: #003467; font-weight: bold; margin-bottom: 0.5rem; }
.uni-limerick { color: #005335; font-weight: bold; margin-bottom: 0.5rem; }

/* --- NEW ZEALAND --- */
.uni-auckland { color: #00467F; font-weight: bold; margin-bottom: 0.5rem; }
.uni-otago { color: #00508F; font-weight: bold; margin-bottom: 0.5rem; }
.uni-wellington { color: #115737; font-weight: bold; margin-bottom: 0.5rem; }
.uni-canterbury { color: #C60C30; font-weight: bold; margin-bottom: 0.5rem; }
.uni-massey { color: #FFC72C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-waikato { color: #BE0027; font-weight: bold; margin-bottom: 0.5rem; }
.uni-lincoln { color: #003865; font-weight: bold; margin-bottom: 0.5rem; }
.uni-aut { color: #000000; font-weight: bold; margin-bottom: 0.5rem; }

/* --- SINGAPORE --- */
.uni-nus { color: #EF7C00; font-weight: bold; margin-bottom: 0.5rem; }
.uni-ntu { color: #C20430; font-weight: bold; margin-bottom: 0.5rem; }
.uni-smu { color: #151C55; font-weight: bold; margin-bottom: 0.5rem; }
.uni-sutd { color: #000000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-suss { color: #004D71; font-weight: bold; margin-bottom: 0.5rem; }
.uni-sit { color: #8F004A; font-weight: bold; margin-bottom: 0.5rem; }

/* --- ITALY --- */
.uni-polimi { color: #003366; font-weight: bold; margin-bottom: 0.5rem; }
.uni-sapienza { color: #812015; font-weight: bold; margin-bottom: 0.5rem; }
.uni-bologna { color: #B30C00; font-weight: bold; margin-bottom: 0.5rem; }
.uni-padua { color: #9B0014; font-weight: bold; margin-bottom: 0.5rem; }
.uni-bocconi { color: #002F5F; font-weight: bold; margin-bottom: 0.5rem; }
.uni-polito { color: #0047BB; font-weight: bold; margin-bottom: 0.5rem; }

/* --- SPAIN --- */
.uni-barcelona { color: #005CA5; font-weight: bold; margin-bottom: 0.5rem; }
.uni-uam { color: #00703C; font-weight: bold; margin-bottom: 0.5rem; }
.uni-ie { color: #003087; font-weight: bold; margin-bottom: 0.5rem; }
.uni-complutense { color: #A41034; font-weight: bold; margin-bottom: 0.5rem; }
.uni-pompeu { color: #C00000; font-weight: bold; margin-bottom: 0.5rem; }
.uni-valencia { color: #00295D; font-weight: bold; margin-bottom: 0.5rem; }
/* Responsive adjustments */
@media (max-width: 768px) {
    .country-badge {
        font-size: 1.5rem !important;
        padding: 0.5rem 1.5rem !important;
        margin-bottom: 1rem;
    }
    .university-header {
        flex-direction: column;
        gap: 1rem;
    }
}
/* =========================================
   5. THEME-SPECIFIC TAB COLORS
   ========================================= */

/* Australia */
.theme-australia .tab-btn {
    border-color: #00008B;
    color: #00008B;
}
.theme-australia .tab-btn.active {
    background: #00008B !important;
    color: white !important;
}

/* Canada */
.theme-canada .tab-btn {
    border-color: #d80621;
    color: #d80621;
}
.theme-canada .tab-btn.active {
    background: #d80621 !important;
    color: white !important;
}

/* Denmark */
.theme-denmark .tab-btn {
    border-color: #C60C30;
    color: #C60C30;
}
.theme-denmark .tab-btn.active {
    background: #C60C30 !important;
    color: white !important;
}

/* France */
.theme-france .tab-btn {
    border-color: #0055A4;
    color: #0055A4;
}
.theme-france .tab-btn.active {
    background: #0055A4 !important;
    color: white !important;
}

/* Germany */
.theme-germany .tab-btn {
    border-color: #000000;
    color: #000000;
}
.theme-germany .tab-btn.active {
    background: #000000 !important;
    color: white !important;
}

/* Ireland */
.theme-ireland .tab-btn {
    border-color: #169B62;
    color: #169B62;
}
.theme-ireland .tab-btn.active {
    background: #169B62 !important;
    color: white !important;
}

/* Italy */
.theme-italy .tab-btn {
    border-color: #009246;
    color: #009246;
}
.theme-italy .tab-btn.active {
    background: #009246 !important;
    color: white !important;
}

/* Netherlands */
.theme-netherlands .tab-btn {
    border-color: #FF6C00;
    color: #FF6C00;
}
.theme-netherlands .tab-btn.active {
    background: #FF6C00 !important;
    color: white !important;
}

/* New Zealand */
.theme-new-zealand .tab-btn {
    border-color: #000000;
    color: #000000;
}
.theme-new-zealand .tab-btn.active {
    background: #000000 !important;
    color: white !important;
}

/* Singapore */
.theme-singapore .tab-btn {
    border-color: #EF3340;
    color: #EF3340;
}
.theme-singapore .tab-btn.active {
    background: #EF3340 !important;
    color: white !important;
}

/* Spain */
.theme-spain .tab-btn {
    border-color: #C60B1E;
    color: #C60B1E;
}
.theme-spain .tab-btn.active {
    background: #C60B1E !important;
    color: white !important;
}

/* Sweden */
.theme-sweden .tab-btn {
    border-color: #006AA7;
    color: #006AA7;
}
.theme-sweden .tab-btn.active {
    background: #006AA7 !important;
    color: white !important;
}

/* Switzerland */
.theme-switzerland .tab-btn {
    border-color: #FF0000;
    color: #FF0000;
}
.theme-switzerland .tab-btn.active {
    background: #FF0000 !important;
    color: white !important;
}

/* UK */
.theme-uk .tab-btn {
    border-color: #00247D;
    color: #00247D;
}
.theme-uk .tab-btn.active {
    background: #00247D !important;
    color: white !important;
}

/* USA */
.theme-usa .tab-btn {
    border-color: #3C3B6E;
    color: #3C3B6E;
}
.theme-usa .tab-btn.active {
    background: #3C3B6E !important;
    color: white !important;
}