@import url('https://fonts.googleapis.com/css2?family=Nunito:wght@200..1000&family=Bubblegum+Sans&display=swap');

/* Card Grid Layout */
.card-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 20px;
    margin-top: 2rem;
}

/* Card Styling */
.card {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    background: var(--secondary);
    border-radius: 0.75rem;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: transform 0.3s ease;
    text-decoration: none;
    color: inherit;
    position: relative;
    overflow: hidden;
    height: 100%;
}

.card:hover {
    transform: translateY(-5px);
}

.card.shaking {
    animation: shake 0.5s;
    animation-iteration-count: 1;
}

@keyframes shake {
    0% { transform: translateY(-5px) rotate(0deg); }
    25% { transform: translateY(-5px) rotate(5deg); }
    50% { transform: translateY(-5px) rotate(-5deg); }
    75% { transform: translateY(-5px) rotate(5deg); }
    100% { transform: translateY(-5px) rotate(0deg); }
}

/* Card Header Styling */
.card-header {
    width: 100%;
    padding: 0.5rem 1rem;
    background: transparent;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
    z-index: 2;
    min-height: 42px;
}

/* Status Label Styling */
.status-label {
    padding: 5px 12px;
    border-radius: 12px;
    font-size: 11px;
    color: #333;
    font-weight: 500;
    text-transform: capitalize;
}

.status-label.active {
    background-color: #d4edda;
    color: #155724;
}

.status-label.disable {
    background-color: #f8d7da;
    color: #721c24;
}

.status-label.soon {
    background-color: #fff3cd;
    color: #856404;
}

.status-label.premium {
    background-color: #e2d6f5;
    color: #5a3d8b;
}

/* Lock Icon Styling */
.lock-icon {
    font-size: 1.5rem;
    color: #ff6f61;
    text-shadow: 1px 1px 1px rgba(0, 0, 0, 0.2);
}

/* Card Content Styling */
.card-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 0 1.5rem 1.5rem;
    position: relative;
    z-index: 1;
}

.card.locked .card-content {
    filter: blur(2px);
}

/* Language Flag Styling */
.language-flag {
    width: 200px;
    height: 150px;
    object-fit: contain;
    border-radius: 1rem;
    margin-bottom: 1rem;
    border: 2px solid transparent;
}

.card.locked .language-flag {
    filter: grayscale(80%);
}

/* Language Name Styling */
.language-name {
    font-family: 'Bubblegum Sans', cursive;
    font-size: 1.25rem;
    color: var(--text);
    font-weight: 600;
    margin-bottom: 0.5rem;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.1);
}


.mode-switch-container {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 1rem;
    justify-content: flex-end;
}

.switch {
    position: relative;
    display: inline-block;
    width: 50px;
    height: 24px;
}

.switch input {
    opacity: 0;
    width: 0;
    height: 0;
}

.slider {
    position: absolute;
    cursor: pointer;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: #ccc;
    transition: 0.4s;
    border-radius: 24px;
}

.slider:before {
    position: absolute;
    content: "";
    height: 18px;
    width: 18px;
    left: 3px;
    bottom: 3px;
    background-color: white;
    transition: 0.4s;
    border-radius: 50%;
}

input:checked + .slider {
    background-color: var(--primary);
}

input:checked + .slider:before {
    transform: translateX(26px);
}

.mode-label {
    font-size: 1rem;
    color: var(--text);
}

/* Responsive Adjustments */
@media (max-width: 375px) {
    .language-flag {
        width: 220px;
        height: 165px;
    }
}

@media (max-width: 320px) {
    .language-flag {
        width: 240px;
        height: 180px;
    }
}

@media (min-width: 576px) {
    .language-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 768px) {
    .language-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

@media (min-width: 992px) {
    .language-grid {
        gap: 30px;
    }
}