﻿:root {
  --header-height: 80px;
  --demo-bar-height: 45px;
  --page-offset: var(--header-height);
}

.header {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    padding: 0 40px;
    background-color: #ffffff;
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    height: 80px;
    transition: top 0.3s ease;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-sizing: border-box;
}

.header.with-demo-warning {
    top: var(--demo-bar-height);
}

.logo-container {
    display: flex;
    align-items: center;
}

.logo-container img {
    width: 200px;
    height: auto;
}

.options-container {
    display: flex;
    align-items: center;
    gap: 30px;
}

.header .options-container a {
    color: #0e2050;
    text-decoration: none;
    position: relative;
    display: inline-block;
    font-weight: 500;
    font-size: 18px;
    transition: color 0.3s ease;
}

.header .options-container a::before {
    content: '';
    position: absolute;
    left: 0;
    bottom: -4px;
    width: 100%;
    height: 2px;
    background-color: #ffd700;
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.header .options-container a:hover {
    color: #0e2050;
}

.header .options-container a:hover::before {
    transform: scaleX(1);
}

.demo-warning {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: #fff3cd;
    color: #856404;
    border-bottom: 1px solid #ffeeba;
    padding: 0 16px;
    font-family: system-ui, sans-serif;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    height: 45px;
    box-sizing: border-box;
}

.demo-warning strong {
    font-weight: bold;
}

.demo-warning a {
    color: #856404;
    text-decoration: underline;
    margin: 0 3px;
}

.demo-warning code {
    background-color: #f8f9fa;
    padding: 2px 4px;
    border-radius: 3px;
    font-family: 'Courier New', monospace;
    font-size: 13px;
}

@media (max-width: 900px) {
    .header {
        padding: 0 20px;
        height: 60px;
    }

    :root {
        --header-height: 60px;
      }
}

@media (max-width: 600px) {
    .header {
        flex-direction: column;
        height: auto;
        padding: 10px;
    }
}

.repo-alert {
    position: relative;
    display: flex;
    align-items: center;
}

/*
 * The bell is only rendered when there is something pending, but it must also
 * disappear while the page is open once every request has been dealt with.
 * An author `display: flex` above outranks the browser's `[hidden]` rule, so
 * the attribute has to be honoured explicitly.
 */
.repo-alert[hidden] {
    display: none;
}

.repo-alert-button {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: #0e2050;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.repo-alert-button svg {
    width: 22px;
    height: 22px;
    fill: currentColor;
}

.repo-alert-button:hover {
    background: rgba(14, 32, 80, 0.08);
}

.repo-alert-button.has-items {
    color: #b8860b;
}

.repo-alert-count {
    position: absolute;
    top: -2px;
    right: -4px;
    min-width: 18px;
    height: 18px;
    padding: 0 4px;
    border-radius: 9px;
    background: #ffd700;
    color: #0e2050;
    font-size: 11px;
    font-weight: 700;
    line-height: 18px;
    text-align: center;
    box-sizing: border-box;
}

.repo-alert-button.is-new {
    animation: repoAlertNudge 0.9s ease 2;
}

@keyframes repoAlertNudge {
    0%, 100% { transform: rotate(0deg); }
    20% { transform: rotate(-12deg); }
    40% { transform: rotate(10deg); }
    60% { transform: rotate(-6deg); }
    80% { transform: rotate(4deg); }
}

.repo-alert-panel {
    position: absolute;
    top: 48px;
    right: 0;
    width: 300px;
    padding: 12px;
    border-radius: 8px;
    background: #ffffff;
    box-shadow: 0 6px 24px rgba(0, 0, 0, 0.18);
    font-size: 14px;
}

.repo-alert-panel[hidden] {
    display: none;
}

.repo-alert-head {
    margin-bottom: 8px;
    color: #0e2050;
    font-weight: 600;
    font-size: 13px;
    text-transform: uppercase;
    letter-spacing: 0.04em;
}

.repo-alert-list {
    list-style: none;
    margin: 0;
    padding: 0;
    max-height: 300px;
    overflow-y: auto;
}

.repo-alert-item {
    padding: 8px 6px;
    border-bottom: 1px solid #eef0f4;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.repo-alert-item:last-child {
    border-bottom: none;
}

.repo-alert-name {
    color: #0e2050;
    font-weight: 600;
}

.repo-alert-domain {
    color: #444;
    word-break: break-all;
}

.repo-alert-meta {
    color: #8a8f98;
    font-size: 12px;
}

.repo-alert-empty {
    padding: 10px 6px;
    color: #6b7280;
    font-style: italic;
}

.repo-alert-more {
    display: block;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #eef0f4;
    color: #0e2050;
    font-weight: 600;
    text-align: center;
    text-decoration: none;
}

.repo-alert-more:hover {
    text-decoration: underline;
}
