*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}
:root {
    --primary: #0ea5e9;
    --secondary: #22c55e;
    --dark: #1e293b;
    --gray: #64748b;
    --light: #f8fafc;
    --lighter: #f1f5f9;
    --border: #e2e8f0;
    --white: #ffffff;
}
body {
    font-family: "Inter", sans-serif;
    background: #0f172a;
    color: var(--white);
    min-height: 100vh;
    overflow-x: hidden;
}
h1,
h2,
h3 {
    font-family: "Poppins", sans-serif;
}

/* Preloader */
#preloader {
    position: fixed;
    inset: 0;
    background: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 99999;
    transition:
        opacity 0.6s ease,
        visibility 0.6s ease;
}
#preloader.hide {
    opacity: 0;
    visibility: hidden;
}
.loader-content {
    text-align: center;
}

/* Map pin bouncing loader */
.loader-map {
    width: 180px;
    height: 180px;
    position: relative;
    margin: 0 auto 24px;
}
.loader-map-circle {
    width: 140px;
    height: 140px;
    border-radius: 50%;
    background: linear-gradient(135deg, #e0f2fe, #ecfdf5, #fef3c7);
    border: 3px solid #e2e8f0;
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0 10px 40px rgba(14, 165, 233, 0.15);
}
.loader-map-circle::before {
    content: "🇱🇰";
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 3.5rem;
}
.loader-pin {
    position: absolute;
    top: 8px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 2.2rem;
    animation: pinBounce 1s ease-in-out infinite;
    filter: drop-shadow(0 4px 8px rgba(239, 68, 68, 0.4));
}
@keyframes pinBounce {
    0%,
    100% {
        transform: translateX(-50%) translateY(0);
    }
    50% {
        transform: translateX(-50%) translateY(-18px);
    }
}

/* Rotating ring */
.loader-ring {
    position: absolute;
    inset: 0;
    border: 3px solid transparent;
    border-top: 3px solid #0ea5e9;
    border-right: 3px solid #22c55e;
    border-radius: 50%;
    animation: ringRotate 1.5s linear infinite;
}
@keyframes ringRotate {
    to {
        transform: rotate(360deg);
    }
}

.loader-content h2 {
    font-size: 2.2rem;
    font-weight: 900;
    color: #1e293b;
    margin-bottom: 8px;
    font-family: "Poppins", sans-serif;
}
.loader-content h2 span {
    color: #0ea5e9;
}
.loader-tagline {
    font-size: 0.9rem;
    color: #94a3b8;
    margin-bottom: 20px;
}
.loader-bar {
    width: 180px;
    height: 4px;
    background: #e2e8f0;
    border-radius: 4px;
    margin: 0 auto;
    overflow: hidden;
}
.loader-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #0ea5e9, #22c55e, #f59e0b);
    border-radius: 4px;
    animation: barLoad 1.8s ease-in-out forwards;
}
@keyframes barLoad {
    0% {
        width: 0%;
    }
    60% {
        width: 75%;
    }
    100% {
        width: 100%;
    }
}

.landing-page {
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    position: relative;
    overflow: hidden;
}

/* Background Image */
.landing-bg {
    position: absolute;
    inset: 0;
    z-index: 0;
    overflow: hidden;
}
.landing-bg-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    animation: bgZoom 40s ease-in-out infinite alternate;
}
@keyframes bgZoom {
    from {
        transform: scale(1);
    }
    to {
        transform: scale(1.12);
    }
}
.landing-bg::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        180deg,
        rgba(0, 0, 0, 0.3) 0%,
        rgba(0, 0, 0, 0.5) 50%,
        rgba(0, 0, 0, 0.6) 100%
    );
}

/* Floating Elements */
.float-element {
    position: absolute;
    font-size: 3rem;
    opacity: 0.25;
    animation: float 6s ease-in-out infinite;
    filter: drop-shadow(0 4px 12px rgba(0, 0, 0, 0.3));
}
.float-element:nth-child(1) {
    top: 10%;
    left: 10%;
    animation-delay: 0s;
}
.float-element:nth-child(2) {
    top: 20%;
    right: 15%;
    animation-delay: 1s;
}
.float-element:nth-child(3) {
    bottom: 30%;
    left: 8%;
    animation-delay: 2s;
}
.float-element:nth-child(4) {
    bottom: 15%;
    right: 10%;
    animation-delay: 3s;
}
.float-element:nth-child(5) {
    top: 50%;
    left: 5%;
    animation-delay: 4s;
}
.float-element:nth-child(6) {
    top: 40%;
    right: 5%;
    animation-delay: 5s;
}
@keyframes float {
    0%,
    100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-30px) rotate(10deg);
    }
}

.landing-content {
    position: relative;
    z-index: 1;
    text-align: center;
    max-width: 1000px;
}

/* Logo */
.landing-logo {
    margin-bottom: 24px;
}
.landing-logo .logo-icon {
    width: 90px;
    height: 90px;
    background: linear-gradient(135deg, var(--primary), var(--secondary));
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.8rem;
    margin: 0 auto 20px;
    box-shadow: 0 10px 40px rgba(14, 165, 233, 0.5);
    animation: logoFloat 3s ease-in-out infinite;
}
@keyframes logoFloat {
    0%,
    100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}
.landing-logo h1 {
    font-size: 3.5rem;
    font-weight: 900;
    letter-spacing: -2px;
    color: var(--white);
    text-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
}
.landing-logo h1 span {
    color: #38bdf8;
}

.landing-subtitle {
    font-size: 1.3rem;
    color: rgba(255, 255, 255, 0.9);
    margin-bottom: 16px;
}
.landing-tagline {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.65);
    margin-bottom: 50px;
}

/* Selection */
.selection-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 30px;
    color: var(--white);
}
.selection-title i {
    color: #fbbf24;
    margin-right: 8px;
}

.selection-cards {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 30px;
    max-width: 800px;
    margin: 0 auto;
}

.selection-card {
    position: relative;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(20px);
    border: 2px solid rgba(255, 255, 255, 0.2);
    border-radius: 24px;
    padding: 40px 30px;
    cursor: pointer;
    transition: all 0.4s ease;
    overflow: hidden;
    text-decoration: none;
    color: var(--white);
}
.selection-card::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(135deg, transparent, rgba(255, 255, 255, 0.05));
    opacity: 0;
    transition: opacity 0.4s;
}
.selection-card:hover::before {
    opacity: 1;
}

/* Foreign Card */
.selection-card.foreign:hover {
    border-color: rgba(14, 165, 233, 0.6);
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px rgba(14, 165, 233, 0.3);
    background: rgba(14, 165, 233, 0.15);
}
.selection-card.foreign::after {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 26px;
    padding: 2px;
    background: linear-gradient(
        135deg,
        var(--primary),
        transparent,
        var(--primary)
    );
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.4s;
}
.selection-card.foreign:hover::after {
    opacity: 1;
}

/* Local Card */
.selection-card.local:hover {
    border-color: rgba(34, 197, 94, 0.6);
    transform: translateY(-8px) scale(1.02);
    box-shadow: 0 20px 60px rgba(34, 197, 94, 0.3);
    background: rgba(34, 197, 94, 0.15);
}
.selection-card.local::after {
    content: "";
    position: absolute;
    inset: -2px;
    border-radius: 26px;
    padding: 2px;
    background: linear-gradient(
        135deg,
        var(--secondary),
        transparent,
        var(--secondary)
    );
    -webkit-mask:
        linear-gradient(#fff 0 0) content-box,
        linear-gradient(#fff 0 0);
    -webkit-mask-composite: xor;
    mask-composite: exclude;
    opacity: 0;
    transition: opacity 0.4s;
}
.selection-card.local:hover::after {
    opacity: 1;
}

.card-icon {
    font-size: 4rem;
    margin-bottom: 20px;
    display: block;
}
.card-flag {
    font-size: 1.2rem;
    margin-bottom: 8px;
    display: block;
}

.selection-card h2 {
    font-size: 1.8rem;
    font-weight: 800;
    margin-bottom: 12px;
}
.selection-card.foreign h2 {
    color: #38bdf8;
}
.selection-card.local h2 {
    color: #4ade80;
}

.selection-card p {
    color: rgba(255, 255, 255, 0.75);
    font-size: 0.95rem;
    line-height: 1.6;
    margin-bottom: 20px;
}

.card-features {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-bottom: 24px;
}
.card-feature {
    background: rgba(255, 255, 255, 0.1);
    padding: 6px 14px;
    border-radius: 50px;
    font-size: 0.8rem;
    color: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.card-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 14px 32px;
    border-radius: 50px;
    font-weight: 700;
    font-size: 1rem;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}
.selection-card.foreign .card-btn {
    background: linear-gradient(135deg, var(--primary), #0284c7);
    color: var(--white);
    box-shadow: 0 4px 20px rgba(14, 165, 233, 0.4);
}
.selection-card.local .card-btn {
    background: linear-gradient(135deg, var(--secondary), #16a34a);
    color: var(--white);
    box-shadow: 0 4px 20px rgba(34, 197, 94, 0.4);
}
.selection-card:hover .card-btn {
    transform: scale(1.05);
}

/* Footer */
.landing-footer {
    position: relative;
    z-index: 1;
    margin-top: 60px;
    text-align: center;
    color: rgba(255, 255, 255, 0.5);
    font-size: 0.85rem;
}
.landing-footer a {
    color: rgba(255, 255, 255, 0.7);
    text-decoration: none;
    transition: color 0.2s;
}
.landing-footer a:hover {
    color: #38bdf8;
}

/* Lang Hint */
.lang-hint {
    margin-top: 40px;
    padding: 16px 24px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(12px);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 16px;
    display: inline-flex;
    align-items: center;
    gap: 12px;
    color: rgba(255, 255, 255, 0.7);
    font-size: 0.9rem;
}
.lang-hint i {
    color: #fbbf24;
}

/* Responsive */
/* ============ RESPONSIVE ============ */
@media (max-width: 1024px) {
    .selection-cards {
        max-width: 700px;
        gap: 24px;
    }
    .selection-card {
        padding: 32px 24px;
    }
}

@media (max-width: 768px) {
    .landing-page {
        padding: 30px 16px;
    }
    .selection-cards {
        grid-template-columns: 1fr;
        gap: 16px;
        max-width: 100%;
    }
    .landing-logo .logo-icon {
        width: 70px;
        height: 70px;
        font-size: 2.2rem;
        border-radius: 18px;
    }
    .landing-logo h1 {
        font-size: 2.2rem;
    }
    .landing-subtitle {
        font-size: 1rem;
    }
    .landing-tagline {
        font-size: 0.88rem;
        margin-bottom: 36px;
    }
    .selection-title {
        font-size: 1.2rem;
        margin-bottom: 20px;
    }
    .selection-card {
        padding: 28px 20px;
        border-radius: 20px;
    }
    .selection-card h2 {
        font-size: 1.4rem;
    }
    .selection-card p {
        font-size: 0.88rem;
    }
    .card-icon {
        font-size: 3rem;
        margin-bottom: 14px;
    }
    .card-flag {
        font-size: 1rem;
    }
    .card-features {
        gap: 6px;
    }
    .card-feature {
        font-size: 0.72rem;
        padding: 5px 10px;
    }
    .card-btn {
        padding: 12px 24px;
        font-size: 0.9rem;
    }
    .float-element {
        display: none;
    }
    .lang-hint {
        font-size: 0.8rem;
        padding: 12px 18px;
    }
    .landing-footer {
        margin-top: 40px;
        font-size: 0.8rem;
    }

    /* Loader */
    .loader-map {
        width: 150px;
        height: 150px;
    }
    .loader-map-circle {
        width: 110px;
        height: 110px;
    }
    .loader-map-circle::before {
        font-size: 2.8rem;
    }
    .loader-pin {
        font-size: 1.8rem;
    }
    .loader-content h2 {
        font-size: 1.8rem;
    }
}

@media (max-width: 480px) {
    .landing-logo .logo-icon {
        width: 60px;
        height: 60px;
        font-size: 1.8rem;
        border-radius: 14px;
    }
    .landing-logo h1 {
        font-size: 1.8rem;
        letter-spacing: -1px;
    }
    .landing-subtitle {
        font-size: 0.9rem;
    }
    .landing-tagline {
        font-size: 0.82rem;
    }
    .selection-card {
        padding: 24px 16px;
        border-radius: 16px;
    }
    .selection-card h2 {
        font-size: 1.2rem;
    }
    .selection-card p {
        font-size: 0.82rem;
        margin-bottom: 14px;
    }
    .card-icon {
        font-size: 2.5rem;
        margin-bottom: 12px;
    }
    .card-btn {
        padding: 10px 20px;
        font-size: 0.85rem;
        width: 100%;
        justify-content: center;
    }
    .card-features {
        margin-bottom: 18px;
    }
    .lang-hint {
        flex-direction: column;
        text-align: center;
        gap: 8px;
        font-size: 0.75rem;
    }
}

.landing-logo {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px; /* ලෝගෝ එක සහ නම අතර පරතරය */
}

.logo-img {
    width: 150px;   /* ඔබේ අවශ්‍යතාවය පරිදි ප්‍රමාණය වෙනස් කරන්න */
    height: 150px;
    object-fit: contain; /* ඉමේජ් එක නියම ප්‍රමාණයට ගැළපීමට */
}
