/**
 * Order Page — tariff cards + extras.
 * Prefix: t1c-op-
 */

/* ── Reset for theme overrides ──────────────────────────────── */
.t1c-op-wrap {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 16px 80px;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
    color: #1a1a2e;
}

.t1c-op-wrap *,
.t1c-op-wrap *::before,
.t1c-op-wrap *::after {
    box-sizing: border-box;
}

/* ── Section titles ─────────────────────────────────────────── */
.t1c-op-section-title {
    font-size: 24px;
    font-weight: 700;
    margin: 0 0 24px;
    text-align: center;
    color: #1a1a2e;
}

/* ── Tabs ────────────────────────────────────────────────────── */
.t1c-op-tabs {
    display: flex;
    justify-content: center;
    gap: 4px;
    margin-bottom: 28px;
    background: #f1f5f9;
    border-radius: 10px;
    padding: 4px;
    max-width: 360px;
    margin-left: auto;
    margin-right: auto;
}

.t1c-op-tab {
    flex: 1;
    padding: 10px 20px !important;
    border: none !important;
    background: transparent !important;
    border-radius: 8px !important;
    font-size: 14px !important;
    font-weight: 600 !important;
    color: #64748b !important;
    cursor: pointer;
    transition: all 0.2s ease;
    line-height: 1.4 !important;
}

.t1c-op-tab-icon {
    font-size: 16px;
    vertical-align: middle;
    margin-right: 2px;
}

.t1c-op-tab:hover {
    color: #334155 !important;
}

.t1c-op-tab--active {
    background: #fff !important;
    color: #1a1a2e !important;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1) !important;
}

/* ── Tab panels ──────────────────────────────────────────────── */
.t1c-op-tab-panel {
    display: none;
}

.t1c-op-tab-panel--active {
    display: block;
}

/* ── Cards grid ──────────────────────────────────────────────── */
.t1c-op-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
    margin-bottom: 16px;
}

.t1c-op-card {
    position: relative;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 14px;
    padding: 24px 20px 20px;
    text-align: center;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    display: flex;
    flex-direction: column;
}

.t1c-op-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
}

.t1c-op-card--popular {
    border-color: #3b82f6;
    box-shadow: 0 0 0 1px #3b82f6;
}

.t1c-op-badge {
    position: absolute;
    top: -10px;
    left: 50%;
    transform: translateX(-50%);
    background: #3b82f6;
    color: #fff;
    font-size: 11px;
    font-weight: 600;
    padding: 3px 12px;
    border-radius: 20px;
    white-space: nowrap;
    letter-spacing: 0.02em;
}

/* Card sections */
.t1c-op-card-header {
    margin-bottom: 16px;
}

.t1c-op-card-name {
    font-size: 16px;
    font-weight: 700;
    margin: 0;
    color: #1a1a2e;
}

.t1c-op-card-body {
    flex: 1;
    margin-bottom: 18px;
    display: flex;
    flex-direction: column;
}

.t1c-op-card-links {
    margin-bottom: 12px;
}

.t1c-op-card-links-num {
    display: block;
    font-size: 40px;
    font-weight: 800;
    line-height: 1;
    color: #1a1a2e;
}

.t1c-op-card-links-label {
    font-size: 13px;
    color: #94a3b8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.t1c-op-card-bonuses {
    margin-top: 6px;
    display: flex;
    flex-direction: column;
    gap: 3px;
    align-items: center;
}

.t1c-op-card-bonus {
    font-size: 12px;
    font-weight: 600;
    color: #16a34a;
    background: #f0fdf4;
    padding: 2px 10px;
    border-radius: 10px;
}

.t1c-op-card-pricing {
    margin-top: auto;
}

.t1c-op-card-price {
    font-size: 22px;
    font-weight: 700;
    color: #1a1a2e;
    margin-bottom: 4px;
}

.t1c-op-card-price .woocommerce-Price-amount {
    font-size: inherit;
    font-weight: inherit;
}

.t1c-op-card-per {
    font-size: 12px;
    color: #94a3b8;
}

.t1c-op-card-per .woocommerce-Price-amount {
    font-size: inherit;
}

.t1c-op-card-deadline {
    font-size: 11px;
    color: #94a3b8;
    margin-top: 4px;
}

.t1c-op-card-footer {
    margin-top: auto;
}

/* ── Note ────────────────────────────────────────────────────── */
.t1c-op-note {
    text-align: center;
    font-size: 13px;
    color: #94a3b8;
    margin: 8px 0 0;
}

/* ── Buttons ─────────────────────────────────────────────────── */
.t1c-op-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 22px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    background: #3b82f6;
    color: #fff;
    width: 100%;
    text-decoration: none;
}

.t1c-op-btn:hover {
    background: #2563eb;
    color: #fff;
    text-decoration: none;
}

.t1c-op-btn:active {
    transform: scale(0.98);
}

.t1c-op-btn--disabled {
    background: #e2e8f0;
    color: #94a3b8;
    cursor: not-allowed;
}

.t1c-op-btn--sm {
    padding: 7px 16px;
    font-size: 13px;
    width: auto;
}

.t1c-op-btn--added {
    background: #16a34a;
}

.t1c-op-btn--adding {
    background: #93c5fd;
    cursor: wait;
}

/* ── Extra services ──────────────────────────────────────────── */
.t1c-op-extras {
    margin-top: 48px;
}

.t1c-op-extras-grid {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.t1c-op-extra {
    display: flex;
    align-items: center;
    gap: 16px;
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 16px 20px;
    transition: box-shadow 0.2s ease;
}

.t1c-op-extra:hover {
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);
}

.t1c-op-extra-icon {
    font-size: 28px;
    line-height: 1;
    flex-shrink: 0;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #f1f5f9;
    border-radius: 10px;
}

.t1c-op-extra-info {
    flex: 1;
    min-width: 0;
}

.t1c-op-extra-name {
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 2px;
    color: #1a1a2e;
}

.t1c-op-extra-name a {
    color: inherit;
    text-decoration: none;
    transition: color 0.15s;
}

.t1c-op-extra-name a:hover {
    color: #3b82f6;
}

.t1c-op-extra-desc {
    font-size: 13px;
    color: #64748b;
    margin: 0;
    line-height: 1.4;
}

.t1c-op-extra-action {
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.t1c-op-extra-price {
    font-size: 16px;
    font-weight: 700;
    color: #1a1a2e;
    white-space: nowrap;
}

/* ── How it works ────────────────────────────────────────────── */
.t1c-op-how {
    margin-top: 48px;
}

.t1c-op-steps {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.t1c-op-step {
    text-align: center;
    padding: 24px 16px;
}

.t1c-op-step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #eff6ff;
    color: #3b82f6;
    font-size: 18px;
    font-weight: 700;
    margin-bottom: 12px;
}

.t1c-op-step h4 {
    font-size: 15px;
    font-weight: 600;
    margin: 0 0 6px;
    color: #1a1a2e;
}

.t1c-op-step p {
    font-size: 13px;
    color: #64748b;
    margin: 0;
    line-height: 1.5;
}

/* ── Sticky cart bar ─────────────────────────────────────────── */
.t1c-op-cart-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    background: #fff;
    border-top: 1px solid #e2e8f0;
    box-shadow: 0 -4px 16px rgba(0, 0, 0, 0.08);
    transform: translateY(100%);
    transition: transform 0.3s ease;
}

.t1c-op-cart-bar--visible {
    transform: translateY(0);
}

.t1c-op-cart-bar-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 12px 20px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.t1c-op-cart-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 15px;
    font-weight: 500;
    color: #1a1a2e !important;
    text-decoration: none !important;
    border-radius: 8px;
    padding: 6px 12px;
    margin: -6px -12px;
    transition: background 0.15s, color 0.15s;
    cursor: pointer;
}

.t1c-op-cart-info:hover {
    background: #f1f5f9;
    color: #3b82f6 !important;
    text-decoration: none !important;
}

.t1c-op-cart-go {
    font-size: 16px;
    opacity: 0;
    transform: translateX(-4px);
    transition: opacity 0.15s, transform 0.15s;
}

.t1c-op-cart-info:hover .t1c-op-cart-go {
    opacity: 1;
    transform: translateX(0);
}

.t1c-op-cart-icon {
    font-size: 20px;
}

.t1c-op-cart-count {
    font-weight: 700;
}

.t1c-op-cart-sep {
    color: #cbd5e1;
}

.t1c-op-cart-total {
    font-weight: 700;
}

.t1c-op-cart-items-label {
    color: #64748b;
}

.t1c-op-btn--checkout {
    width: auto;
    padding: 10px 28px;
    background: #16a34a;
    font-size: 15px;
}

.t1c-op-btn--checkout:hover {
    background: #15803d;
    color: #fff;
}

/* ── Home link ────────────────────────────────────────────────── */
.t1c-op-home-link {
    text-align: center;
    margin-top: 24px;
    font-size: 14px;
}

.t1c-op-home-link a {
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.2s ease;
}

.t1c-op-home-link a:hover {
    color: #2563eb;
    text-decoration: underline;
}

/* ── Clear cart button ───────────────────────────────────────── */
.t1c-op-cart-clear {
    background: none !important;
    border: 1px solid #e2e8f0 !important;
    border-radius: 6px !important;
    padding: 6px 14px !important;
    font-size: 12px !important;
    color: #94a3b8 !important;
    cursor: pointer;
    transition: all 0.2s ease;
    white-space: nowrap;
}

.t1c-op-cart-clear:hover {
    color: #dc2626 !important;
    border-color: #dc2626 !important;
}

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 900px) {
    .t1c-op-cards {
        grid-template-columns: repeat(2, 1fr);
    }
    .t1c-op-steps {
        grid-template-columns: 1fr;
        gap: 8px;
    }
}

@media (max-width: 600px) {
    .t1c-op-wrap {
        padding: 0 12px 90px;
    }
    .t1c-op-section-title {
        font-size: 20px;
    }
    .t1c-op-cards {
        grid-template-columns: 1fr;
        gap: 12px;
    }
    .t1c-op-card {
        padding: 20px 16px 16px;
    }
    .t1c-op-card-links-num {
        font-size: 32px;
    }
    .t1c-op-card-price {
        font-size: 18px;
    }
    .t1c-op-extra {
        flex-wrap: wrap;
    }
    .t1c-op-extra-action {
        width: 100%;
        justify-content: space-between;
        margin-top: 8px;
    }
    .t1c-op-cart-bar-inner {
        flex-direction: column;
        gap: 8px;
    }
    .t1c-op-btn--checkout {
        width: 100%;
    }
}

/* ─── Quantity picker modal ─────────────────────────────────
   Shared by every .t1c-op-add-to-cart button on the quick-order
   page. Opens on click, shows [-] [N] [+] controls + live total,
   submits addToCart(btn, N). Indigo palette to match site. */
.t1c-op-modal {
    position: fixed;
    inset: 0;
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.18s ease;
}
.t1c-op-modal[hidden] { display: none; }
.t1c-op-modal--open { opacity: 1; pointer-events: auto; }

.t1c-op-modal-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(17, 24, 39, 0.55);
    backdrop-filter: blur(2px);
}

.t1c-op-modal-card {
    position: relative;
    width: min(420px, calc(100% - 32px));
    background: #fff;
    border-radius: 14px;
    padding: 28px 28px 24px;
    box-shadow: 0 20px 60px rgba(17, 24, 39, 0.25);
    transform: translateY(12px) scale(0.98);
    transition: transform 0.18s ease;
    text-align: center;
}
.t1c-op-modal--open .t1c-op-modal-card {
    transform: translateY(0) scale(1);
}

.t1c-op-modal-close {
    position: absolute;
    top: 10px;
    right: 12px;
    background: transparent;
    border: 0;
    font-size: 26px;
    line-height: 1;
    color: #9ca3af;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 6px;
    transition: background 0.12s, color 0.12s;
}
.t1c-op-modal-close:hover {
    background: #f3f4f6;
    color: #374151;
}

.t1c-op-modal-title {
    margin: 0 0 6px;
    font-size: 18px;
    font-weight: 600;
    color: #1f2937;
}
.t1c-op-modal-price-one {
    font-size: 13px;
    color: #6b7280;
    margin-bottom: 22px;
}

.t1c-op-modal-qty-wrap {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 18px;
}

.t1c-op-qty-btn {
    width: 44px;
    height: 44px;
    border: 1px solid #d6deff;
    background: #f5f7ff;
    color: #3b4a99;
    border-radius: 10px;
    font-size: 22px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.12s, border-color 0.12s, color 0.12s;
    line-height: 1;
}
.t1c-op-qty-btn:hover {
    background: #667eea;
    border-color: #667eea;
    color: #fff;
}
.t1c-op-qty-btn:active { transform: translateY(1px); }

.t1c-op-qty-input {
    width: 90px;
    height: 44px;
    padding: 0 10px;
    border: 1px solid #d1d5db;
    border-radius: 10px;
    font-size: 18px;
    font-weight: 600;
    text-align: center;
    color: #1f2937;
    background: #fff;
    -moz-appearance: textfield;
}
.t1c-op-qty-input:focus {
    outline: none;
    border-color: #667eea;
    box-shadow: 0 0 0 3px rgba(102, 126, 234, 0.18);
}
.t1c-op-qty-input::-webkit-outer-spin-button,
.t1c-op-qty-input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

.t1c-op-modal-total {
    font-size: 15px;
    color: #374151;
    margin-bottom: 20px;
}
.t1c-op-modal-total-val {
    color: #1f2937;
    font-size: 20px;
    font-weight: 700;
    margin-left: 4px;
}

.t1c-op-modal-actions {
    display: flex;
    flex-direction: column;
    gap: 8px;
    align-items: stretch;
}
.t1c-op-modal-submit {
    background: #667eea;
    color: #fff;
    border: 1px solid #667eea;
    border-radius: 10px;
    padding: 12px 20px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.12s, border-color 0.12s;
}
.t1c-op-modal-submit:hover {
    background: #5a6fd6;
    border-color: #5a6fd6;
}

.t1c-op-modal-cancel {
    background: transparent;
    border: 0;
    color: #6b7280;
    font-size: 13px;
    padding: 6px 12px;
    cursor: pointer;
    text-decoration: underline;
    text-underline-offset: 3px;
}
.t1c-op-modal-cancel:hover { color: #374151; }

@media (max-width: 480px) {
    .t1c-op-modal-card {
        padding: 24px 18px 18px;
    }
    .t1c-op-qty-btn { width: 48px; height: 48px; font-size: 24px; }
    .t1c-op-qty-input { height: 48px; font-size: 20px; }
}
