:root {
    --primary: #047B3C;
    --secondary: #E52226;
    --bg: #f6f7f9;
    --surface: #ffffff;
    --text: #1a1a1a;
    --text-muted: #5a5a5a;
    --border: #e3e3e6;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.04), 0 2px 8px rgba(0, 0, 0, 0.06);
    --shadow-hover: 0 4px 12px rgba(0, 0, 0, 0.10), 0 2px 4px rgba(0, 0, 0, 0.06);
    --appbar-height: 64px;
}

* {
    box-sizing: border-box;
}

html, body {
    margin: 0;
    padding: 0;
    background: var(--bg);
    color: var(--text);
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    min-height: 100vh;
}

.appbar {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    height: var(--appbar-height);
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 0 24px;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
    z-index: 10;
}

.appbar .logo {
    width: 40px;
    height: 40px;
    object-fit: contain;
}

.appbar .title {
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--text);
}

main {
    padding: calc(var(--appbar-height) + 32px) 24px 48px;
    max-width: 1200px;
    margin: 0 auto;
}

.status {
    text-align: center;
    color: var(--text-muted);
    font-size: 1rem;
    margin-top: 32px;
}

.status.error {
    color: var(--secondary);
}

.no-access {
    max-width: 520px;
    margin: 48px auto 0;
    padding: 32px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: var(--shadow);
    text-align: center;
}

.no-access h2 {
    margin: 0 0 12px;
    font-size: 1.5rem;
    font-weight: 500;
    color: var(--text);
}

.no-access p {
    margin: 0;
    color: var(--text-muted);
    line-height: 1.5;
}

.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 16px;
    margin-top: 16px;
}

.card {
    display: flex;
    align-items: center;
    gap: 20px;
    min-height: 140px;
    padding: 24px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: 8px;
    box-shadow: var(--shadow);
    cursor: pointer;
    font-family: inherit;
    color: var(--text);
    transition: transform 120ms ease, box-shadow 120ms ease, border-color 120ms ease;
    text-align: left;
}

.card:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: var(--shadow-hover);
    border-color: var(--primary);
}

.card:focus-visible {
    outline: 2px solid var(--primary);
    outline-offset: 2px;
}

.card:disabled {
    cursor: not-allowed;
    opacity: 0.5;
}

.card .flag {
    width: 56px;
    height: 40px;
    object-fit: cover;
    border-radius: 3px;
    flex-shrink: 0;
}

.card .country-name {
    font-size: 1.25rem;
    font-weight: 500;
}

@media (max-width: 480px) {
    main {
        padding: calc(var(--appbar-height) + 16px) 16px 32px;
    }

    .appbar {
        padding: 0 16px;
    }

    .appbar .title {
        font-size: 1.25rem;
    }
}
