@import url('https://fonts.googleapis.com/css2?family=Outfit:wght@400;600;800&family=Poppins:wght@400;600&display=swap');

:root {
    --primary-neon: #00f0ff;
    --secondary-neon: #bd00ff;
    --accent-pink: #ff007f;
    --dark-bg-glass: rgba(10, 25, 30, 0.75);
    --border-glass: rgba(0, 240, 255, 0.25);
    --text-primary: #ffffff;
    --text-muted: rgba(255, 255, 255, 0.7);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Outfit', 'Poppins', sans-serif;
    background-image: url(wp9456159.jpg);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 60px 20px 100px;
    color: var(--text-primary);
    overflow-x: hidden;
}

/* Subtle background overlay to dim background image just enough for readability */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(5, 15, 20, 0.6), rgba(5, 10, 15, 0.8));
    z-index: -1;
}

/* ---------------- COUNTRY INFO APP DESIGN ---------------- */
h1 {
    font-size: 2.2rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 2px;
    background: linear-gradient(45deg, var(--primary-neon), #ffffff, var(--secondary-neon));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 30px rgba(0, 240, 255, 0.3);
    margin-bottom: 25px;
    text-align: center;
    display: flex;
    align-items: center;
    gap: 12px;
}

.container {
    width: 480px;
    max-width: 100%;
    background: var(--dark-bg-glass);
    padding: 30px;
    border-radius: 20px;
    border: 1px solid var(--border-glass);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5),
        0 0 25px rgba(0, 240, 255, 0.1);
    backdrop-filter: blur(14px);
    -webkit-backdrop-filter: blur(14px);
    transition: all 0.4s ease;
    margin-top: 10px;
}

.container:hover {
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.6),
        0 0 35px rgba(0, 240, 255, 0.2);
    border-color: rgba(0, 240, 255, 0.4);
}

input {
    width: 100%;
    padding: 14px 18px;
    font-size: 16px;
    font-family: inherit;
    border-radius: 12px;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: var(--text-primary);
    margin-bottom: 20px;
    outline: none;
    transition: all 0.3s ease;
}

input::placeholder {
    color: rgba(255, 255, 255, 0.4);
}

input:focus {
    background: rgba(255, 255, 255, 0.08);
    border-color: var(--primary-neon);
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.3);
}

#searchBtn {
    width: 100%;
    padding: 14px;
    background: linear-gradient(135deg, var(--primary-neon), var(--secondary-neon));
    color: #050d12;
    border: none;
    font-size: 16px;
    font-weight: 700;
    font-family: inherit;
    border-radius: 12px;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(0, 240, 255, 0.2);
}

#searchBtn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(0, 240, 255, 0.4);
    filter: brightness(1.1);
}

#searchBtn:active {
    transform: translateY(1px);
}

.flag {
    width: 100%;
    border-radius: 12px;
    margin: 25px 0 20px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.1);
    transition: transform 0.3s ease;
}

.flag:hover {
    transform: scale(1.02);
}

.info {
    display: flex;
    flex-direction: column;
    gap: 12px;
    background: rgba(255, 255, 255, 0.03);
    padding: 20px;
    border-radius: 12px;
    border: 1px solid rgba(255, 255, 255, 0.05);
}

.info p {
    font-size: 15px;
    line-height: 1.5;
    color: var(--text-muted);
    border-bottom: 1px dashed rgba(255, 255, 255, 0.07);
    padding-bottom: 8px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.info p:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.info span {
    font-weight: 600;
    color: var(--primary-neon);
    text-shadow: 0 0 5px rgba(0, 240, 255, 0.2);
}

.info a {
    color: var(--accent-pink);
    text-decoration: none;
    font-weight: 600;
    border-bottom: 1px solid transparent;
    transition: all 0.3s ease;
}

.info a:hover {
    color: #ff3399;
    border-bottom-color: #ff3399;
    text-shadow: 0 0 8px rgba(255, 0, 127, 0.4);
}

#result p {
    text-align: center;
    color: var(--accent-pink);
    font-weight: 600;
    margin-top: 20px;
    font-size: 16px;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        opacity: 0.8;
    }

    50% {
        opacity: 0.4;
    }

    100% {
        opacity: 0.8;
    }
}

/* ================= SOCIAL ICONS (BOTTOM RIGHT) ================= */
.social-links {
    position: fixed;
    bottom: 25px;
    right: 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    z-index: 999;
}

.social-links a {
    width: 48px;
    height: 48px;
    display: flex;
    justify-content: center;
    align-items: center;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}

.social-links svg {
    width: 20px;
    height: 20px;
    fill: #ffffff;
    transition: fill 0.3s ease, transform 0.3s ease;
}

/* Brands Hover Themes */
.social-links a[title="LinkedIn"]:hover {
    background: rgba(10, 102, 194, 0.2);
    border-color: #0a66c2;
    box-shadow: 0 0 15px rgba(10, 102, 194, 0.5);
    transform: scale(1.15) translateY(-3px);
}

.social-links a[title="LinkedIn"]:hover svg {
    fill: #0a66c2;
}

.social-links a[title="Instagram"]:hover {
    background: rgba(225, 48, 108, 0.2);
    border-color: #e1306c;
    box-shadow: 0 0 15px rgba(225, 48, 108, 0.5);
    transform: scale(1.15) translateY(-3px);
}

.social-links a[title="Instagram"]:hover svg {
    fill: #e1306c;
}

.social-links a[title="X (Twitter)"]:hover {
    background: rgba(255, 255, 255, 0.2);
    border-color: #ffffff;
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
    transform: scale(1.15) translateY(-3px);
}

.social-links a[title="X (Twitter)"]:hover svg {
    fill: #ffffff;
}

/* ================= FOOTER DESIGN CREDIT ================= */
.design-credit {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: 1px;
    color: var(--text-muted);
    background: rgba(10, 25, 30, 0.85);
    border: 1px solid rgba(255, 255, 255, 0.08);
    padding: 8px 22px;
    border-radius: 30px;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.3);
    animation: fadeIn 1.5s ease-in-out, floatingText 4.5s infinite ease-in-out;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    width: max-content;
}

@keyframes fadeIn {
    0% {
        opacity: 0;
        transform: translate(-50%, 15px);
    }

    100% {
        opacity: 1;
        transform: translate(-50%, 0px);
    }
}

@keyframes floatingText {
    0% {
        transform: translate(-50%, 0px);
    }

    50% {
        transform: translate(-50%, -5px);
    }

    100% {
        transform: translate(-50%, 0px);
    }
}

.design-credit span {
    color: var(--primary-neon);
    font-weight: 700;
    text-shadow: 0 0 8px rgba(0, 240, 255, 0.4);
}

/* ================= HOME STATE / SUGGESTIONS ================= */
.home-state {
    margin-top: 25px;
    display: flex;
    flex-direction: column;
    gap: 15px;
    animation: fadeIn 0.8s ease-in-out;
}

.promo-text {
    font-size: 14px;
    line-height: 1.6;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
    background: rgba(255, 255, 255, 0.02);
    padding: 15px;
    border-radius: 10px;
    border: 1px dashed rgba(0, 240, 255, 0.15);
}

.quick-suggest {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: center;
}

.suggest-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    background: linear-gradient(90deg, #00f0ff, #ff007f, #bd00ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 10px rgba(189, 0, 255, 0.1);
}

.suggest-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.suggest-tag {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.15);
    color: #ffffff;
    font-size: 13px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    font-family: inherit;
}

/* Distinct Neon Colors for Suggestion tags */
.suggest-tag:nth-child(1) {
    border-color: rgba(0, 240, 255, 0.4);
    color: #00f0ff;
}
.suggest-tag:nth-child(1):hover {
    background: rgba(0, 240, 255, 0.15);
    box-shadow: 0 0 12px rgba(0, 240, 255, 0.3);
    transform: translateY(-2px);
}

.suggest-tag:nth-child(2) {
    border-color: rgba(255, 0, 127, 0.4);
    color: #ff007f;
}
.suggest-tag:nth-child(2):hover {
    background: rgba(255, 0, 127, 0.15);
    box-shadow: 0 0 12px rgba(255, 0, 127, 0.3);
    transform: translateY(-2px);
}

.suggest-tag:nth-child(3) {
    border-color: rgba(189, 0, 255, 0.4);
    color: #bd00ff;
}
.suggest-tag:nth-child(3):hover {
    background: rgba(189, 0, 255, 0.15);
    box-shadow: 0 0 12px rgba(189, 0, 255, 0.3);
    transform: translateY(-2px);
}

.suggest-tag:nth-child(4) {
    border-color: rgba(0, 255, 127, 0.4);
    color: #00ff7f;
}
.suggest-tag:nth-child(4):hover {
    background: rgba(0, 255, 127, 0.15);
    box-shadow: 0 0 12px rgba(0, 255, 127, 0.3);
    transform: translateY(-2px);
}

.suggest-tag:nth-child(5) {
    border-color: rgba(255, 174, 0, 0.4);
    color: #ffae00;
}
.suggest-tag:nth-child(5):hover {
    background: rgba(255, 174, 0, 0.15);
    box-shadow: 0 0 12px rgba(255, 174, 0, 0.3);
    transform: translateY(-2px);
}

/* ================= LOADER SPIN ================= */
.loader-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 15px;
    padding: 30px 0;
    animation: fadeIn 0.4s ease-in-out;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 3px solid rgba(0, 240, 255, 0.1);
    border-top-color: var(--primary-neon);
    border-radius: 50%;
    animation: spin 1s linear infinite;
    box-shadow: 0 0 15px rgba(0, 240, 255, 0.2);
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loader-container p {
    font-size: 14px;
    color: var(--primary-neon) !important;
    text-shadow: 0 0 8px rgba(0, 240, 255, 0.4);
    animation: pulse 1.5s infinite !important;
    letter-spacing: 1.2px;
    text-transform: uppercase;
    font-weight: 600;
}

/* ================= RETRY BUTTON ================= */
.retry-btn {
    display: block;
    margin: 15px auto 0;
    padding: 10px 20px;
    background: transparent;
    border: 1px solid var(--accent-pink);
    color: var(--accent-pink);
    border-radius: 8px;
    font-family: inherit;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.retry-btn:hover {
    background: rgba(255, 0, 127, 0.1);
    box-shadow: 0 0 12px rgba(255, 0, 127, 0.2);
    transform: translateY(-1px);
}

/* ================= HISTORY SECTION ================= */
.history-section {
    margin-top: 10px;
    display: flex;
    flex-direction: column;
    gap: 10px;
    width: 100%;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
    padding-top: 20px;
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    padding: 0 4px;
}

.history-label {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1.5px;
    background: linear-gradient(90deg, #00f0ff, #bd00ff);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    text-shadow: 0 0 10px rgba(0, 240, 255, 0.1);
}

.clear-history-btn {
    background: transparent;
    border: none;
    color: var(--accent-pink);
    font-size: 11px;
    font-weight: 600;
    cursor: pointer;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    opacity: 0.7;
    transition: opacity 0.3s ease;
}

.clear-history-btn:hover {
    opacity: 1;
    text-shadow: 0 0 5px rgba(255, 0, 127, 0.4);
}

.history-tag {
    background: rgba(0, 240, 255, 0.03);
    border: 1px solid rgba(0, 240, 255, 0.2);
    color: var(--primary-neon);
    font-size: 12px;
    font-weight: 500;
    padding: 5px 12px;
    border-radius: 20px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-family: inherit;
}

.history-tag:hover {
    background: rgba(0, 240, 255, 0.1);
    border-color: var(--primary-neon);
    box-shadow: 0 0 10px rgba(0, 240, 255, 0.3);
    transform: translateY(-1px);
}