/* Kundens godkännandesida (/k/<token>). Bygger på urbrev.se:s main.css; allt här är avgränsat till .ub-* eller till sidan. */
#main header.major.ub-head { margin-bottom: 0.8rem !important; padding-bottom: 0 !important; }
#ub-form { scroll-margin-top: 4.3rem; }
.pris-label { margin-bottom: 0.4rem !important; }
.pris { color: green !important; border-bottom: none !important; padding-bottom: 0 !important; margin-bottom: 0.5rem !important; }
@media (max-width: 768px) { .pris { font-size: 50px !important; } }
.button.down:after { transform: rotate(90deg); }
.knapplinje { border-bottom: 1px solid; padding-bottom: 1.6rem; margin-bottom: 2rem; }
.knapplinje .actions { margin-bottom: 1.1rem; }
#giltighet { font-size: .68rem; letter-spacing: .14em; margin: 0; }

.ub-form-wrap { margin-top: 0; }
.ub-box { border: 1px solid rgba(99, 116, 133, .25); border-radius: 10px; padding: 1.2rem 1.4rem .6rem; }
.ub-options h6 { margin-bottom: .8rem; }
.ub-opt { margin: 0 0 .9rem; }
.ub-opt label { margin: 0; }
.ub-price { font-weight: 700; white-space: nowrap; }
.ub-ord { opacity: .65; font-size: .9em; white-space: nowrap; }
.ub-opt-note { font-size: .8rem; opacity: .75; margin: -.2rem 0 1.1rem; }
.ub-options { margin: 0 0 3.6rem; }
.ub-total { text-align: right; font-size: 1.1rem; margin: .3rem 0 .6rem; padding-top: .8rem; border-top: 1px solid rgba(99, 116, 133, .2); }
.ub-total[hidden] { display: none; }
.ub-fine { font-size: .8rem; opacity: .75; margin-top: 1rem; text-align: center; }
.ub-hp { position: absolute !important; left: -9999px !important; width: 1px; height: 1px; overflow: hidden; }
.ub-err { color: #b3261e; font-size: .85rem; margin: .35rem 0 0 !important; min-height: 0; }
.ub-err:empty { display: none; }
.ub-err-main { text-align: center; margin-bottom: 1rem !important; font-size: .95rem; }
.field.ub-invalid input[type="text"] { border-color: #b3261e !important; box-shadow: 0 0 0 1px #b3261e !important; }

/* telefon med landsnummer och flagga */
/* Landsnummer och nummer är ett sammansatt fält: en ram, med knappen (flagga + riktnummer) till vänster. */
.ub-phone { display: flex; align-items: stretch; position: relative; height: 3rem; background: #fff; border: solid 1px rgba(99, 116, 133, .25); border-radius: 10px; }
.ub-phone:focus-within { border-color: #000; box-shadow: 0 0 0 1px #000; }
.ub-phone input[type="text"], .field.ub-invalid .ub-phone input[type="text"] { flex: 1; min-width: 0; height: 100%; border: 0 !important; box-shadow: none !important; background: transparent !important; border-radius: 0 10px 10px 0; }
.field.ub-invalid .ub-phone { border-color: #b3261e; box-shadow: 0 0 0 1px #b3261e; }
.ub-cc { position: relative; flex: none; }
.ub-cc .ub-cc-btn { display: flex; align-items: center; gap: 8px; height: 100%; padding: 0 1rem; margin: 0; font: inherit; font-size: 1rem; letter-spacing: normal; text-transform: none; line-height: 1; color: inherit; background: transparent; border: 0; border-right: solid 1px rgba(99, 116, 133, .25); box-shadow: none; border-radius: 10px 0 0 10px; cursor: pointer; }
.ub-cc .ub-cc-btn:focus { outline: none; box-shadow: none; background: #f3f7fa; }
.ub-flag { width: 22px; height: 16px; object-fit: cover; border-radius: 2px; box-shadow: 0 0 0 1px rgba(0, 0, 0, .12); vertical-align: middle; }
.ub-cc-caret { width: 0; height: 0; border-left: 5px solid transparent; border-right: 5px solid transparent; border-top: 6px solid #888; margin-left: 2px; }
.ub-cc .ub-cc-list { position: absolute; z-index: 20; top: calc(100% + 4px); left: 0; margin: 0; padding: 4px; list-style: none; width: 280px; max-width: calc(100vw - 48px); max-height: 260px; overflow-y: auto; background: #fff; color: #333; border: 1px solid rgba(99, 116, 133, .25); border-radius: 10px; box-shadow: 0 8px 24px rgba(0, 0, 0, .14); }
.ub-cc .ub-cc-list[hidden] { display: none; }
.ub-cc .ub-cc-list li { display: flex; align-items: center; gap: 10px; margin: 0; padding: 10px; border-radius: 4px; cursor: pointer; font-size: 15px; line-height: 1.2; }
.ub-cc .ub-cc-list li:before { display: none; }
.ub-cc .ub-cc-list li:hover, .ub-cc .ub-cc-list li[aria-selected="true"] { background: #eef4f8; }
.ub-cc .ub-cc-list li .ub-cc-dial { margin-left: auto; color: #777; }

/* tacksidan som visas efter godkännandet */
.ub-thanks .qf-done-title { margin-bottom: 1.2rem; }
.ub-thanks .qf-thanks-body p { margin-bottom: 1rem; }
.ub-thanks .qf-thanks-heading { margin-top: 1.5rem; }

/* Bockarna i UrBrevs blå (#125376, samma som knapparna) i stället för svart. */
#ub-approve input[type="checkbox"]:checked + label:before { background-color: #125376; border-color: #125376; color: #fff; }
#ub-approve input[type="checkbox"]:focus + label:before { border-color: #125376; box-shadow: 0 0 0 1px #125376; }

/* Transportförsäkringen: diskret ruta med liten bild. */
.ub-ins { display: flex; align-items: center; gap: .9rem; max-width: 34rem; margin: 1.8rem auto 3.5rem; padding: .65rem 1rem; text-align: left; background: #f3fafd; border: 1px solid #d6eef8; border-radius: 12px; }
.ub-ins img { flex: none; width: 46px; height: 46px; display: block; border-radius: 50%; }
.ub-ins-text { display: flex; flex-direction: column; gap: .1rem; }
.ub-ins-text strong { font-size: .8rem; color: #125376; letter-spacing: .05em; text-transform: uppercase; }
.ub-ins-text span { font-size: .82rem; line-height: 1.45; color: #4a4a4a; text-transform: none; letter-spacing: normal; font-weight: 400; }
.ub-ins-text a { color: #125376; text-decoration: underline; border-bottom: 0; }
@media (max-width: 480px) { .ub-ins { gap: .7rem; padding: .55rem .8rem; margin-top: 1.4rem; margin-bottom: -1.8rem; } .ub-ins img { width: 38px; height: 38px; } .ub-ins-text span { font-size: .78rem; } }
/* Etikett med antal platser kvar, "i"-ringen och popupen med förklaring (samma utseende som popuparna på statussidan). */
.ub-left { display: inline-block; margin-top: .45rem; padding: .18rem .7rem .18rem .55rem; border-radius: 14px; background: rgba(169, 130, 55, .13); color: #7c5d1f; font-size: .72rem; font-weight: 700; letter-spacing: .06em; text-transform: uppercase; line-height: 1.5; }
.ub-left:before { content: ""; display: inline-block; width: .5rem; height: .5rem; margin-right: .45rem; border-radius: 50%; background: #a98237; vertical-align: .05em; }
.ub-left-last { background: rgba(176, 58, 46, .1); color: #9b2f24; }
.ub-left-last:before { background: #b03a2e; }
.ub-opt label .ub-left { display: table; }
.ub-info { display: inline-flex; align-items: center; justify-content: center; width: 20px; height: 20px; margin-left: .35em; border: 1px solid var(--urbrev-blue, #2e91d4); border-radius: 50%; color: var(--urbrev-blue, #2e91d4); font: 700 12px/1 Arial, sans-serif; font-style: normal; vertical-align: middle; cursor: pointer; }
.ub-info:hover, .ub-info:focus { background: var(--urbrev-blue, #2e91d4); color: #fff; outline: none; }
.ub-pop { display: none; position: fixed; inset: 0; z-index: 100000; }
.ub-pop.is-open { display: block; }
.ub-pop-backdrop { position: absolute; inset: 0; background: rgba(0, 0, 0, .22); backdrop-filter: blur(3px); -webkit-backdrop-filter: blur(3px); animation: ubPopFade .4s ease forwards; }
.ub-pop-box { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(calc(100% - 48px), 980px); min-height: 560px; background: #fff; border-radius: 24px; box-shadow: 0 20px 60px rgba(0, 0, 0, .25); overflow: hidden; animation: ubPopFade .4s ease forwards; z-index: 1; }
.ub-pop-grid { display: grid; grid-template-columns: minmax(340px, 1.05fr) minmax(380px, .95fr); min-height: 560px; }
.ub-pop-grid.ub-pop-noimg { grid-template-columns: 1fr; }
.ub-pop-image { background: center center / cover no-repeat; }
.ub-pop-content { position: relative; display: flex; align-items: center; justify-content: center; padding: 44px 40px; background: #fff; }
.ub-pop-inner { width: 100%; max-width: 360px; text-align: center; }
.ub-pop-box h1 { margin: 0 0 14px; color: #111; font-size: 52px; line-height: 1.08; font-family: Oswald, sans-serif; font-weight: 600; }
.ub-pop-box p { margin: 0; color: #444; font-size: 16px; line-height: 1.45; font-family: Lato, sans-serif; font-weight: 500; }
.ub-pop-box p + p { margin-top: 18px; }
.ub-pop-close { position: absolute; top: 14px; right: 14px; width: 32px; height: 32px; cursor: pointer; }
.ub-pop-close:before, .ub-pop-close:after { content: ""; position: absolute; left: 6px; top: 15px; width: 20px; height: 2px; border-radius: 1px; background: #555; }
.ub-pop-close:before { transform: rotate(45deg); }
.ub-pop-close:after { transform: rotate(-45deg); }
.ub-pop-close:hover:before, .ub-pop-close:hover:after, .ub-pop-close:focus:before, .ub-pop-close:focus:after { background: #111; }
.ub-pop-close:focus { outline: none; }
body.ub-pop-open { overflow: hidden; }
@keyframes ubPopFade { from { opacity: 0; } to { opacity: 1; } }
@keyframes ubPopUp { from { transform: translateY(100%); } to { transform: translateY(0); } }
@media screen and (max-width: 736px) {
    .ub-left { font-size: .66rem; letter-spacing: .03em; }
    .ub-pop-box { left: 0; right: 0; top: auto; bottom: 0; transform: none; width: 100%; min-height: 0; padding: 24px 20px calc(24px + env(safe-area-inset-bottom, 0px)); border-radius: 24px 24px 0 0; overflow: visible; animation: ubPopUp .35s ease-out forwards; }
    .ub-pop-box::after { content: ""; position: absolute; left: 0; right: 0; top: 100%; height: calc(120px + env(safe-area-inset-bottom, 0px)); background: #fff; }
    .ub-pop-grid { display: block; min-height: 0; }
    .ub-pop-image { display: none; }
    .ub-pop-content { display: block; padding: 0; }
    .ub-pop-inner { max-width: none; }
    .ub-pop-box h1 { margin-bottom: 14px; font-size: 42px; line-height: 1.1; }
    .ub-pop-box p { margin-bottom: 8px; }
    .ub-pop-close { top: 8px; right: 8px; }
}
