/*
 * Intelwebhost — custom styles for Lagom 2.4.5
 * ---------------------------------------------------------------------------
 * This file replaces the old 665 KB templates/lagom2/custom.css, which was a
 * copy of Lagom 2.1's compiled stylesheet with ".container" renamed to
 * ".containerx". None of it was actually custom, and on 2.4.5 it fought with
 * the theme's own CSS. Everything below styles only Intelwebhost's own markup
 * (includes/iwh/*.tpl), under an .iwh- prefix so nothing can collide with Lagom.
 *
 * Lagom loads this file automatically — do not link it from a template.
 */

/* ==========================================================================
   1. Brand top bar (order form / cart pages)
   ========================================================================== */

.iwh-topbar {
    background-color: var(--body-bg, #fff);
    border-bottom: 1px solid var(--border-color, #e2e8f0);
}

.iwh-topbar-inner {
    display: flex;
    align-items: center;
    height: 74px;
    max-width: 1160px;
    margin: 0 auto;
    padding: 0 16px;
}

.iwh-logo {
    display: flex;
    align-items: center;
    height: 40px;
    max-width: 100%;
}

.iwh-logo img {
    height: auto;
    max-height: 32px;
    width: auto;
}

.iwh-topbar-nav {
    display: flex;
    align-items: center;
    margin: 0 0 0 auto;
    padding: 0;
    list-style: none;
    white-space: nowrap;
}

.iwh-topbar-nav > li + li {
    margin-left: 8px;
}

.iwh-topbar-nav > li > a {
    display: flex;
    align-items: center;
    padding: 6px 8px;
    color: var(--text-color, #536080);
    text-decoration: none;
    border-radius: 6px;
    transition: color .2s ease, background-color .2s ease;
}

.iwh-topbar-nav > li > a:hover,
.iwh-topbar-nav > li > a:focus {
    color: var(--primary-color, #144fc4);
    background-color: var(--bg-light, #f6f7f8);
    text-decoration: none;
}

.iwh-topbar-nav i,
.iwh-cart-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    font-size: 12px;
    color: #99a5c2;
    transition: color .2s ease;
}

.iwh-cart-icon svg {
    width: 18px;
    height: 18px;
    fill: #99a5c2;
    transition: fill .2s ease;
}

.iwh-topbar-nav > li > a:hover .iwh-cart-icon svg,
.iwh-topbar-nav > li > a:focus .iwh-cart-icon svg {
    fill: var(--primary-color, #144fc4);
}

.iwh-topbar-nav > li > a:hover i,
.iwh-topbar-nav > li > a:focus i {
    color: var(--primary-color, #144fc4);
}

.iwh-item-text {
    margin-left: 8px;
    font-size: 14px;
    line-height: 1;
}

@media (max-width: 575px) {
    .iwh-topbar-inner { height: 62px; }
    .iwh-item-text { display: none; }
}

/* ==========================================================================
   2. Promo banner + countdown
   ========================================================================== */

.iwh-promo {
    background: linear-gradient(90deg, #0d1785, #1a4db4);
    color: #fff;
}

.iwh-promo-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    max-width: 1160px;
    margin: 0 auto;
    padding: 12px 16px;
}

.iwh-promo-text {
    font-size: 14px;
    line-height: 1.5;
    color: rgba(255, 255, 255, .9);
}

.iwh-promo-text strong {
    color: #fff;
    font-weight: 600;
}

.iwh-promo-timer {
    display: flex;
    gap: 8px;
}

.iwh-timer {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 46px;
    padding: 4px 6px;
    background-color: rgba(255, 255, 255, .12);
    border-radius: 6px;
}

.iwh-timer > span:first-child {
    font-size: 16px;
    font-weight: 600;
    line-height: 1.2;
    font-variant-numeric: tabular-nums;
}

.iwh-timer > span:last-child {
    font-size: 9px;
    letter-spacing: .5px;
    text-transform: uppercase;
    color: rgba(255, 255, 255, .64);
}

@media (max-width: 767px) {
    .iwh-promo-inner { justify-content: center; text-align: center; }
    .iwh-timer { min-width: 40px; }
}

/* ==========================================================================
   3. Cart footer
   ========================================================================== */

.iwh-cart-footer {
    border-top: 1px solid var(--border-color, #e2e8f0);
    background-color: var(--body-bg, #fff);
}

.iwh-cart-footer-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    max-width: 1160px;
    margin: 0 auto;
    padding: 20px 16px;
}

.iwh-cart-footer-copy {
    margin: 0;
    font-size: 13px;
    color: var(--text-muted, #7c88a5);
}

.iwh-cart-footer-cards {
    display: flex;
    align-items: center;
    gap: 8px;
}

.iwh-cart-footer-cards img {
    height: 26px;
    width: auto;
}

@media (max-width: 575px) {
    .iwh-cart-footer-inner { justify-content: center; text-align: center; }
}

/* ==========================================================================
   4. Client area — addon note area (WSCN)
   ========================================================================== */

.iwh-note-top {
    margin: 0 0 15px;
}

.iwh-note-top:empty {
    display: none;
}

/* ==========================================================================
   5. Order form — cart design
   --------------------------------------------------------------------------
   Reproduces the Intelwebhost cart look that used to live as an inline
   <style> block inside orderforms/lagom2/viewcart.tpl.

   That block was written against Lagom 2.1 markup and needed ~90 !important
   declarations to fight the theme's own flex layout. Lagom 2.4.5 already
   lays the cart out with flex columns (.title-col / .qty-col / .price-col /
   .actions-col), so the same design needs only colours, spacing and type —
   no !important, no layout overrides.

   Scoped to .page-order so nothing leaks into the client area.
   ========================================================================== */

/* ---- Page title spacing ---- */
.page-order .order-content > .header-lined {
    margin-top: 0;
    padding-top: 0;
    margin-bottom: 10px;
}

/* ---- Panel ---- */
.page-order .panel-cart {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, .05);
    margin-bottom: 10px;
    overflow: hidden;
    padding: 0;
}

/* ---- Heading row ---- */
.page-order .panel-cart .cart-heading {
    background: #f8fafc;
    border-bottom: 1px solid #e2e8f0;
    padding: 14px 24px;
    margin: 0;
    font-size: 12px;
    font-weight: 600;
    letter-spacing: .5px;
    text-transform: uppercase;
    color: #64748b;
}

/* ---- Item rows ---- */
.page-order .panel-cart .cart-item {
    padding: 20px 24px;
    background: #fff;
    border-bottom: 1px solid #e2e8f0;
}

.page-order .panel-cart .cart-item:last-of-type {
    border-bottom: none;
}

/* ---- Product name + domain ---- */
.page-order .panel-cart .cart-item-title-main {
    display: block;
    margin-bottom: 4px;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.4;
    color: #0f172a;
}

.page-order .panel-cart .cart-item-title-small {
    display: block;
    font-size: 13px;
    font-weight: 400;
    color: #64748b;
}

/* Globe icon, only on rows that carry an actual domain name */
.page-order .panel-cart .cart-item-title-domain {
    display: flex;
    align-items: center;
}

.page-order .panel-cart .cart-item-title-domain::before {
    content: "";
    display: inline-block;
    flex-shrink: 0;
    width: 14px;
    height: 14px;
    margin-right: 6px;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Ccircle cx='12' cy='12' r='10'%3E%3C/circle%3E%3Cline x1='2' y1='12' x2='22' y2='12'%3E%3C/line%3E%3Cpath d='M12 2a15.3 15.3 0 0 1 4 10 15.3 15.3 0 0 1-4 10 15.3 15.3 0 0 1-4-10 15.3 15.3 0 0 1 4-10z'%3E%3C/path%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
    background-position: center;
}

/* ---- Pricing ---- */
.page-order .panel-cart .cart-item-price {
    font-size: 16px;
    font-weight: 600;
    color: #0f172a;
    border: none;
}

.page-order .panel-cart .price-cycle-inline {
    margin-left: 2px;
    font-size: 13px;
    font-weight: 400;
    color: #64748b;
}

/* Renewal / pro-rata text sits on its own line under the price */
.page-order .panel-cart .cart-item-pricing .renewal {
    display: block;
    width: 100%;
    margin-top: 4px;
    font-size: .85em;
    font-weight: 400;
    color: #94a3b8;
}

/* ---- Edit / remove buttons ---- */
.page-order .panel-cart .cart-item-actions .btn {
    padding: 4px 6px;
    margin: 0 2px;
    line-height: 1;
    opacity: .6;
    transition: opacity .2s ease;
}

.page-order .panel-cart .cart-item-actions .btn:hover,
.page-order .panel-cart .cart-item-actions .btn:focus {
    opacity: 1;
}

/* ---- Panel footer (Continue Shopping / Empty Cart) ---- */
.page-order .panel-cart .panel-footer {
    background: #f8fafc;
    border-top: 1px solid #e2e8f0;
    padding: 14px 24px;
    margin: 0;
}

/* ---- Mobile ---- */
@media (max-width: 767px) {
    .page-order .panel-cart .cart-item {
        padding: 16px;
    }
    .page-order .panel-cart .cart-heading,
    .page-order .panel-cart .panel-footer {
        padding: 12px 16px;
    }
}

/* ---- Order summary: "Savings" label instead of the promo description ---- */
.page-order .iwh-promo-description {
    display: none;
}

.page-order .list-item-promo .primary-discount {
    color: #16a34a;
    font-weight: 600;
}
