body {
    margin: 0;
    font-family: 'Montserrat Alternates', Arial, sans-serif;
    background: #f3f6f9;
    color: #111;
}

a {
    color: #0a3d62;
    text-decoration: none;
    transition: color 0.2s ease;
}

a:hover {
    text-decoration: underline;
}

.content {
    min-height: 100vh;
    background: linear-gradient(180deg, rgba(243,246,249,0.9) 0%, rgba(255,255,255,1) 45%);
    padding-bottom: 60px;
}

.header {
    background: #ffffff;
    padding: 28px 0 12px;
    text-align: center;
    border-bottom: 4px solid #0a3d62;
}

.header .box {
    max-width: 820px;
    margin: 0 auto;
    padding: 0 16px;
}

.header h1 {
    font-family: 'Archivo Black', sans-serif;
    font-size: 44px;
    margin: 12px 0 4px;
    letter-spacing: 4px;
    color: #0a3d62;
}

.logo-link {
    text-decoration: none;
    display: inline-block;
}

.logo-link:hover {
    text-decoration: none;
}

.header .subtitle {
    font-family: 'Montserrat Alternates', sans-serif;
    text-transform: uppercase;
    letter-spacing: 0.35rem;
    font-size: 12px;
    color: #444;
    margin-bottom: 18px;
}

.header .social-link img {
    width: 150px;
    border-radius: 15px;
    background: #fff;
    box-shadow: 0 10px 20px rgba(0,0,0,0.08);
    transition: transform 0.2s ease;
}

.header .social-link img:hover {
    transform: translateY(-3px);
}

.quick-links {
    margin-top: 18px;
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.main {
    width: 1140;
    max-width: 1440px;
    margin: 0 auto;
    padding: 32px 24px 64px;
    background: #ffffff;
    box-shadow: 0 12px 34px rgba(10,61,98,0.08);
    border-radius: 18px;
    box-sizing: border-box;
}

@media (max-width: 860px) {
    .main {
        margin: 24px 16px;
        padding: 24px 18px 48px;
    }

    .header h1 {
        font-size: 32px;
        letter-spacing: 2px;
    }
}

.w100 {
    width: 100%;
    display: block;
}

.tavlingar {
    font-size: 24px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 2px;
    margin: 0 0 12px;
    text-align: center;
}

.list,
.swish {
    display: block;
    margin: 8px 0;
    text-align: center;
    color: #222;
    font-size: 15px;
    line-height: 1.6;
}

.swish {
    color: #0a3d62;
}

.list a,
.swish a {
    font-weight: 600;
}

.muted {
    color: #666;
    font-size: 14px;
    text-align: center;
    margin: 12px 0;
}

.series {
    border: 1px solid rgba(10,61,98,0.18);
    border-radius: 16px;
    padding: 22px;
    margin-bottom: 18px;
    background: rgba(255,255,255,0.9);
    box-shadow: 0 10px 22px rgba(10,61,98,0.08);
}

.series h3 {
    font-size: 22px;
    margin: 0 0 8px;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-align: center;
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    background: #0a3d62;
    color: #fff;
    border-radius: 8px;
    text-transform: uppercase;
    font-size: 12px;
    letter-spacing: 1.6px;
    border: none;
    cursor: pointer;
    transition: background 0.2s ease, box-shadow 0.2s ease;
}

.btn:hover {
    background: #062c4d;
    text-decoration: none;
    box-shadow: 0 8px 18px rgba(10,61,98,0.25);
}

.btn.secondary {
    background: #7b8d9e;
}

.btn.secondary:hover {
    background: #5d6a76;
}

select {
    padding: 8px 12px;
    border: 2px solid #b7c4cf;
    border-radius: 8px;
    background: #fff;
    color: #0a3d62;
    font-size: 14px;
    font-family: 'Montserrat Alternates', Arial, sans-serif;
    cursor: pointer;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
    appearance: none;
    -webkit-appearance: none;
    -moz-appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='14' viewBox='0 0 12 12'%3E%3Cpath fill='%230a3d62' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 14px;
    padding-right: 35px;
}

select:hover {
    border-color: #0a3d62;
    box-shadow: 0 2px 8px rgba(10,61,98,0.15);
}

select:focus {
    outline: none;
    border-color: #0a3d62;
    box-shadow: 0 0 0 3px rgba(10,61,98,0.1);
}

select option {
    padding: 8px;
    background: #fff;
    color: #0a3d62;
}

.race-card {
    border-radius: 18px;
    padding: 24px;
    margin: 28px 0;
    background: linear-gradient(135deg, rgba(255,255,255,0.94), rgba(243,246,249,0.92));
    box-shadow: 0 16px 35px rgba(10,61,98,0.12);
}

.race-card .list,
.race-card .swish {
    text-align: center;
}

.searchresult {
    z-index: 1001;
}

.search-box {
    width: 100%;
    max-width: 420px;
    margin: 0 auto 16px;
    position: relative;
    display: block;
}

.search-box input[type="text"] {
    width: 100%;
    height: 36px;
    padding: 5px 12px;
    border: 1px solid #b7c4cf;
    border-radius: 8px;
    font-size: 15px;
    box-sizing: border-box;
}

.result {
    position: absolute;
    z-index: 999;
    top: 100%;
    left: 0;
    width: 100%;
    background: #fff;
    border: 1px solid #b7c4cf;
    border-top: none;
    border-radius: 0 0 8px 8px;
    box-shadow: 0 12px 24px rgba(0,0,0,0.08);
}

.search-box input[type="text"],
.result {
    box-sizing: border-box;
}

.result p {
    margin: 0;
    padding: 9px 12px;
    cursor: pointer;
}

.result p:hover {
    background: #f2f2f2;
}

.anmalan_tavlingslista {
    font-family: 'Montserrat Alternates', sans-serif;
    width: 100%;
    background-color: #f1f3f6;
    padding: 22px;
    box-sizing: border-box;
    margin-top: 16px;
    border-radius: 14px;
}

.anmalan {
    display: block;
    width: 100%;
}

.round {
    border-radius: 8px;
    padding: 6px;
    //background: #ffffff;
}

.black_overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(10, 61, 98, 0.75);
    backdrop-filter: blur(4px);
    z-index: 1001;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

.white_content {
    display: none;
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    max-width: 500px;
    max-height: 85vh;
    padding: 0;
    background-color: #ffffff;
    z-index: 1002;
    overflow: hidden;
    border-radius: 20px;
    box-shadow: 0 24px 60px rgba(10, 61, 98, 0.3);
    animation: slideIn 0.3s ease;
}

@keyframes slideIn {
    from {
        opacity: 0;
        transform: translate(-50%, -45%);
    }
    to {
        opacity: 1;
        transform: translate(-50%, -50%);
    }
}

.white_content .popup-header {
    background: linear-gradient(135deg, #0a3d62 0%, #062c4d 100%);
    color: white;
    padding: 24px 28px;
    border-radius: 20px 20px 0 0;
    font-family: 'Archivo Black', sans-serif;
    font-size: 20px;
    letter-spacing: 1px;
    text-transform: uppercase;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.white_content .popup-close {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    font-size: 20px;
    line-height: 1;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    font-family: Arial, sans-serif;
}

.white_content .popup-close:hover {
    background: rgba(255, 255, 255, 0.3);
    transform: rotate(90deg);
}

.white_content .popup-body {
    padding: 28px;
    overflow-y: auto;
    max-height: calc(85vh - 100px);
}

.white_content .popup-body::-webkit-scrollbar {
    width: 8px;
}

.white_content .popup-body::-webkit-scrollbar-track {
    background: #f1f3f6;
    border-radius: 4px;
}

.white_content .popup-body::-webkit-scrollbar-thumb {
    background: #b7c4cf;
    border-radius: 4px;
}

.white_content .popup-body::-webkit-scrollbar-thumb:hover {
    background: #7b8d9e;
}

.white_content .popup-body input[type="text"],
.white_content .popup-body input[type="email"] {
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.white_content .popup-body input[type="text"]:focus,
.white_content .popup-body input[type="email"]:focus {
    outline: none;
    border-color: #0a3d62;
    box-shadow: 0 0 0 3px rgba(10, 61, 98, 0.1);
}

.white_content .popup-body input[type="text"]:hover,
.white_content .popup-body input[type="email"]:hover {
    border-color: #7b8d9e;
}

.bullet li::before {
    content: "•";
    color: #0a3d62;
    margin-right: 8px;
}

.box {
    width: 100%;
    box-sizing: border-box;
}

.content .main .list img {
    border-radius: 12px;
    box-shadow: 0 8px 20px rgba(0,0,0,0.10);
}

.gdpr {
    max-width: 820px;
    margin: 0 auto;
    color: #555;
    text-align: left;
    font-size: 14px;
    line-height: 1.8;
}

.footer {
    padding: 40px 20px 60px;
    text-align: center;
    color: #555;
    font-size: 14px;
    background: #ffffff;
    border-top: 1px solid rgba(10,61,98,0.1);
    line-height: 1.8;
}

.footer strong {
    display: block;
    letter-spacing: 2px;
    text-transform: uppercase;
    font-size: 12px;
    color: #0a3d62;
    margin-bottom: 12px;
}

table {
    width: 100%;
    border-collapse: collapse;
}

th,
td {
    padding: 8px;
    border-bottom: 1px solid rgba(10,61,98,0.12);
    text-align: left;
}

tr:nth-child(even) {
    background: rgba(10,61,98,0.03);
}

/* Admin: resultatrapport (mobil + drag-rader) */
.resultatrapport-wrap {
    max-width: 100%;
}

.resultatrapport-form-actions {
    margin-top: 1.25rem;
    display: flex;
    flex-wrap: wrap;
    gap: 0.75rem;
    align-items: center;
}

.resultatrapport-save-status {
    display: inline-flex;
    align-items: center;
    min-height: 2rem;
    padding: 0.3rem 0.55rem;
    border-radius: 6px;
    font-size: 0.8rem;
    color: #475569;
    background: #f3f6f9;
    border: 1px solid rgba(10, 61, 98, 0.12);
}

.resultatrapport-save-status.is-saving {
    color: #7c5a00;
    background: #fff7df;
    border-color: #e8c965;
}

.resultatrapport-save-status.is-saved {
    color: #166534;
    background: #ecfdf3;
    border-color: #86efac;
}

.resultatrapport-save-status.is-error {
    color: #991b1b;
    background: #fef2f2;
    border-color: #fca5a5;
}

.resultatrapport-rows {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.resultatrapport-row {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-start;
    gap: 0.5rem 0.75rem;
    padding: 0.75rem 0.65rem;
    background: rgba(255, 255, 255, 0.85);
    border: 1px solid rgba(10, 61, 98, 0.15);
    border-radius: 10px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.06);
}

.resultatrapport-row.sortable-chosen {
    opacity: 0.95;
    box-shadow: 0 4px 14px rgba(10, 61, 98, 0.18);
}

.resultatrapport-drag-handle {
    flex: 0 0 auto;
    cursor: grab;
    user-select: none;
    touch-action: none;
    font-size: 1.1rem;
    line-height: 1.5;
    padding: 0.35rem 0.45rem;
    min-width: 2.25rem;
    min-height: 2.75rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #0a3d62;
    border-radius: 6px;
    background: rgba(10, 61, 98, 0.06);
}

.resultatrapport-drag-handle:active {
    cursor: grabbing;
}

.resultatrapport-slot {
    flex: 0 0 auto;
    font-weight: 600;
    color: #0a3d62;
    min-width: 2rem;
    padding-top: 0.45rem;
}

.resultatrapport-fields {
    flex: 1 1 200px;
    display: flex;
    flex-wrap: wrap;
    gap: 0.65rem 1rem;
    align-items: flex-end;
}

.resultatrapport-field {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    min-width: 0;
}

.resultatrapport-field-startnr {
    flex: 0 1 5.5rem;
}

.resultatrapport-field-varv {
    flex: 0 1 8rem;
}

.resultatrapport-field-klass {
    flex: 1 1 12rem;
}

.resultatrapport-field-name {
    flex: 1 1 100%;
}

.resultatrapport-label {
    font-size: 0.75rem;
    font-weight: 600;
    color: #555;
    text-transform: uppercase;
    letter-spacing: 0.03em;
}

.resultatrapport-input,
.resultatrapport-select {
    min-height: 2.75rem;
    padding: 0.45rem 0.55rem;
    font-size: 1rem;
    border: 1px solid rgba(10, 61, 98, 0.2);
    border-radius: 8px;
    width: 100%;
    box-sizing: border-box;
}

.resultatrapport-name {
    font-size: 0.95rem;
    color: #333;
}

.resultatrapport-actions {
    flex: 0 0 auto;
    align-self: flex-end;
    padding-bottom: 0.15rem;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 0.35rem;
}

.resultatrapport-row-save-status {
    display: inline-flex;
    align-items: center;
    padding: 0.2rem 0.45rem;
    border-radius: 6px;
    font-size: 0.72rem;
    font-weight: 600;
    border: 1px solid rgba(10, 61, 98, 0.14);
    color: #475569;
    background: #f3f6f9;
}

.resultatrapport-row-save-status.is-pending {
    color: #7c5a00;
    background: #fff7df;
    border-color: #e8c965;
}

.resultatrapport-row-save-status.is-saving {
    color: #7c5a00;
    background: #fff7df;
    border-color: #e8c965;
}

.resultatrapport-row-save-status.is-saved {
    color: #166534;
    background: #ecfdf3;
    border-color: #86efac;
}

.resultatrapport-row-save-status.is-error {
    color: #991b1b;
    background: #fef2f2;
    border-color: #fca5a5;
}

.resultatrapport-actions .btn.resultatrapport-delete,
.resultatrapport-actions .btn.resultatrapport-remove-row {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.45rem;
    min-height: 2.75rem;
    min-width: auto;
    padding: 0.5rem 0.9rem;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.06em;
    line-height: 1.2;
    color: #8b1a1a;
    background: #fff8f8;
    border: 2px solid #c53030;
    box-shadow: 0 1px 0 rgba(0, 0, 0, 0.04);
}

.resultatrapport-actions .btn.resultatrapport-delete:hover,
.resultatrapport-actions .btn.resultatrapport-remove-row:hover {
    color: #fff;
    background: #c53030;
    border-color: #9b1c1c;
    box-shadow: 0 4px 14px rgba(197, 48, 48, 0.35);
}

.resultatrapport-delete-icon {
    font-size: 1.15rem;
    line-height: 1;
}

.resultatrapport-delete-label {
    white-space: nowrap;
}

@media (max-width: 640px) {
    .resultatrapport-row {
        flex-direction: column;
        align-items: stretch;
    }

    .resultatrapport-drag-handle,
    .resultatrapport-slot {
        align-self: flex-start;
    }

    .resultatrapport-fields {
        flex-direction: column;
        align-items: stretch;
    }

    .resultatrapport-field-startnr,
    .resultatrapport-field-varv,
    .resultatrapport-field-klass {
        flex: 1 1 auto;
        width: 100%;
    }

    .resultatrapport-actions {
        align-self: stretch;
        align-items: stretch;
    }

    .resultatrapport-actions .btn {
        width: 100%;
    }
}
