/* ============================================================
   BARWA - COOKIE CONSENT
   File: cookie-consent.css  (script: cookie-consent.js)

   The popup, the Cookie settings window and the box shown in
   place of a map or investor tool until the visitor accepts.
   English (LTR) and Arabic (RTL) share these rules: logical
   properties put the popup bottom-left in English and
   bottom-right in Arabic, opposite the Ask Barwa button. The
   popup and window rules are scoped to #barwa-cc so the site's
   own styles and these never mix.
   ============================================================ */

#barwa-cc {
    --cc-navy: #00205b;
    --cc-text: #252525;
    --cc-muted: #5b6474;
    --cc-line: #e3e7ef;
    --cc-soft: #f4f6fa;

    font-family: "Lusail", "Segoe UI", Tahoma, Arial, sans-serif;
    font-size: 15px;
    line-height: 1.55;
    color: var(--cc-text);
    text-align: start;
}

#barwa-cc *,
#barwa-cc *::before,
#barwa-cc *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    font-family: inherit;
    letter-spacing: normal;
    text-transform: none;
}

#barwa-cc [hidden] {
    display: none !important;
}

/* ---- The popup ---------------------------------------------------------------------------------------------- */

#barwa-cc .cc-card {
    position: fixed;
    z-index: 2147483000;
    bottom: 28px;
    inset-inline-start: 28px;
    width: min(470px, calc(100vw - 56px));
    max-height: calc(100vh - 56px);
    overflow: auto;
    background: #fff;
    border: 1px solid var(--cc-line);
    border-radius: 18px;
    box-shadow: 0 18px 50px rgba(0, 32, 91, 0.22), 0 2px 6px rgba(0, 32, 91, 0.08);
    animation: cc-up 0.35s ease-out;
}

@keyframes cc-up {
    from { opacity: 0; transform: translateY(16px); }
    to { opacity: 1; transform: none; }
}

@media (prefers-reduced-motion: reduce) {
    #barwa-cc .cc-card { animation: none; }
}

#barwa-cc .cc-top {
    display: flex;
    gap: 14px;
    align-items: center;
    padding: 22px 24px 0;
}

#barwa-cc .cc-icon {
    flex: 0 0 44px;
    height: 44px;
    border-radius: 12px;
    background: var(--cc-soft);
    color: var(--cc-navy);
    display: grid;
    place-items: center;
}

#barwa-cc h2 {
    font-size: 19px;
    font-weight: 700;
    line-height: 1.3;
    color: var(--cc-navy);
}

#barwa-cc .cc-body {
    padding: 12px 24px 0;
    font-size: 14.5px;
    color: var(--cc-muted);
}

#barwa-cc a,
#barwa-cc .cc-link {
    color: var(--cc-navy);
    font-size: inherit;
    font-weight: 600;
    text-decoration: underline;
    text-underline-offset: 3px;
    background: none;
    border: 0;
    cursor: pointer;
}

#barwa-cc .cc-buttons {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 20px 24px 22px;
}

#barwa-cc .cc-btn {
    flex: 1 1 0;
    min-width: 130px;
    min-height: 46px;
    padding: 8px 16px;
    border: 1.5px solid var(--cc-navy);
    border-radius: 10px;
    background: #fff;
    color: var(--cc-navy);
    font-size: 15px;
    font-weight: 600;
    line-height: 1.3;
    cursor: pointer;
    transition: background-color 0.15s, color 0.15s;
}

#barwa-cc .cc-btn:hover {
    background: var(--cc-soft);
}

#barwa-cc .cc-btn--primary {
    background: var(--cc-navy);
    color: #fff;
}

#barwa-cc .cc-btn--primary:hover {
    background: #173b78;
}

#barwa-cc .cc-btn:focus-visible,
#barwa-cc .cc-link:focus-visible,
#barwa-cc .cc-switch:focus-visible,
#barwa-cc a:focus-visible,
#barwa-cc .cc-close:focus-visible {
    outline: 3px solid #9f692a;
    outline-offset: 2px;
}

#barwa-cc .cc-foot {
    display: flex;
    justify-content: center;
    padding: 12px 24px;
    border-top: 1px solid var(--cc-line);
    background: #fafbfd;
    font-size: 14.5px;
}

/* ---- Cookie settings window ---------------------------------------------------------------------------------- */

#barwa-cc .cc-dim {
    position: fixed;
    inset: 0;
    z-index: 2147483001;
    display: grid;
    place-items: center;
    padding: 20px;
    background: rgba(0, 20, 58, 0.55);
}

#barwa-cc .cc-modal {
    width: min(620px, 100%);
    max-height: calc(100vh - 40px);
    overflow: auto;
    background: #fff;
    border-radius: 18px;
    box-shadow: 0 24px 60px rgba(0, 0, 0, 0.3);
}

#barwa-cc .cc-modal-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
    padding: 22px 26px;
    background: var(--cc-navy);
}

#barwa-cc .cc-modal-head h2 {
    color: #fff;
}

#barwa-cc .cc-close {
    flex: 0 0 38px;
    height: 38px;
    border: 0;
    border-radius: 10px;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    font-size: 24px;
    line-height: 1;
    cursor: pointer;
}

#barwa-cc .cc-modal-body {
    padding: 20px 26px 6px;
    font-size: 14.5px;
    color: var(--cc-muted);
}

#barwa-cc .cc-cat {
    margin: 14px 0;
    padding: 16px 18px;
    border: 1px solid var(--cc-line);
    border-radius: 14px;
}

#barwa-cc .cc-cat-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

#barwa-cc .cc-cat h3 {
    font-size: 16px;
    font-weight: 700;
    color: var(--cc-navy);
}

#barwa-cc .cc-cat p {
    margin-top: 6px;
    font-size: 14px;
}

#barwa-cc .cc-always {
    padding: 4px 10px;
    border-radius: 999px;
    background: #e7f6ee;
    color: #1a7f4b;
    font-size: 13px;
    font-weight: 600;
    white-space: nowrap;
}

#barwa-cc .cc-switch {
    position: relative;
    flex: 0 0 48px;
    width: 48px;
    height: 28px;
    border: 0;
    border-radius: 999px;
    background: #c5cfe0;
    cursor: pointer;
    transition: background-color 0.15s;
}

#barwa-cc .cc-switch::after {
    content: "";
    position: absolute;
    top: 3px;
    inset-inline-start: 3px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    background: #fff;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.25);
    transition: inset-inline-start 0.15s;
}

#barwa-cc .cc-switch[aria-checked="true"] {
    background: var(--cc-navy);
}

#barwa-cc .cc-switch[aria-checked="true"]::after {
    inset-inline-start: 23px;
}

#barwa-cc .cc-modal-foot {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    padding: 14px 26px 24px;
}

#barwa-cc .cc-modal-foot .cc-btn {
    flex: 1 1 0;
}

/* ---- Phones: the popup is a sheet along the bottom; the Ask Barwa button waits until the visitor chooses ----- */

@media (max-width: 640px) {
    #barwa-cc .cc-card {
        inset-inline: 0;
        bottom: 0;
        width: 100%;
        max-height: 85vh;
        border: 0;
        border-radius: 18px 18px 0 0;
    }

    #barwa-cc .cc-top { padding: 20px 20px 0; }
    #barwa-cc .cc-body { padding: 10px 20px 0; }
    #barwa-cc .cc-buttons { flex-direction: column; padding: 16px 20px 18px; }
    #barwa-cc .cc-btn { flex: none; width: 100%; }
    #barwa-cc .cc-dim { align-items: end; padding: 0; }
    #barwa-cc .cc-modal { max-height: 92vh; border-radius: 18px 18px 0 0; }
    #barwa-cc .cc-modal-head { padding: 18px 20px; }
    #barwa-cc .cc-modal-body { padding: 16px 20px 4px; }
    #barwa-cc .cc-modal-foot { padding: 12px 20px 20px; }
    #barwa-cc .cc-modal-foot .cc-btn { flex: 1 1 100%; }

    html.cc-open #barwa-ask-root .barwa-ask-button { display: none; }
}

/* ---- The box in place of a map or investor tool ---------------------------------------------------------------- */

.cc-held {
    display: grid;
    place-items: center;
    width: 100%;
    min-height: 300px;
    padding: 24px;
    border-radius: inherit;
    background: linear-gradient(135deg, #eef2f9, #dfe6f2);
    font-family: "Lusail", "Segoe UI", Tahoma, Arial, sans-serif;
    text-align: center;
    box-sizing: border-box;
}

.cc-held-inner {
    max-width: 380px;
    font-size: 15px;
    line-height: 1.5;
    color: #3d4757;
}

.cc-held-inner svg {
    display: block;
    margin: 0 auto;
}

.cc-held-title {
    display: block;
    margin: 10px 0 4px;
    font-size: 18px;
    font-weight: 700;
    color: #00205b;
}

.cc-held-btn {
    margin-top: 14px;
    min-height: 44px;
    padding: 0 22px;
    border: 0;
    border-radius: 10px;
    background: #00205b;
    color: #fff;
    font-family: inherit;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
}

.cc-held-btn:hover {
    background: #173b78;
}

.cc-held-btn:focus-visible,
.cc-held-link:focus-visible {
    outline: 3px solid #9f692a;
    outline-offset: 2px;
}

.cc-held-link {
    display: block;
    margin-top: 10px;
    font-size: 14px;
    color: #00205b;
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* One line, for a thin frame such as the share ticker strip. */
.cc-held--slim {
    padding: 8px 16px;
}

.cc-held--slim .cc-held-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: center;
    gap: 4px 14px;
    max-width: none;
    font-size: 14px;
}

.cc-held--slim .cc-held-title {
    margin: 0;
    font-size: 15px;
}

.cc-held--slim .cc-held-btn {
    margin-top: 0;
    min-height: 36px;
    padding: 0 16px;
    font-size: 14px;
}
