.tracking-page {
    min-height: calc(100vh - 60px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 16px 80px;
    background: var(--bg-soft);
}

.tracking-header {
    text-align: center;
    max-width: 560px;
    margin-bottom: 40px;
}

.tracking-icon-wrap {
    width: 80px;
    height: 80px;
    background: linear-gradient(135deg, #d1fae5 0%, #ecfdf5 100%);
    border-radius: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    box-shadow: 0 8px 24px rgba(16, 185, 129, 0.18);
}

.tracking-icon-wrap svg {
    width: 40px;
    height: 40px;
    color: #059669;
}

.tracking-header h1 {
    font-size: 2rem;
    font-weight: 800;
    color: var(--text-dark);
    margin-bottom: 12px;
    letter-spacing: -0.02em;
}

.tracking-header p {
    font-size: 1rem;
    color: var(--text-gray);
    line-height: 1.6;
    margin: 0;
}

.btn-lacak-page {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    width: 100%;
    max-width: 380px;
    padding: 16px 28px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    border-radius: 14px;
    font-size: 1.05rem;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 6px 20px rgba(16, 185, 129, 0.35);
}

.btn-lacak-page:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 28px rgba(16, 185, 129, 0.4);
}

.popup-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(6px);
    -webkit-backdrop-filter: blur(6px);
    z-index: 1000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 16px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.popup-overlay.active {
    opacity: 1;
    visibility: visible;
}

.popup-card {
    background: white;
    border-radius: 20px;
    width: 100%;
    max-width: 400px; 
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.18);
    overflow: hidden;
    transform: translateY(20px) scale(0.95);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.popup-overlay.active .popup-card {
    transform: translateY(0) scale(1);
}

.popup-header {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    padding: 28px 24px 22px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.popup-header::before, .popup-header::after {
    content: '';
    position: absolute;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    pointer-events: none;
}
.popup-header::before { width: 120px; height: 120px; top: -50px; right: -30px; }
.popup-header::after { width: 80px; height: 80px; bottom: -30px; left: -20px; }

.popup-close {
    position: absolute;
    top: 12px;
    right: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
    z-index: 10;
}
.popup-close:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: rotate(90deg);
}

.popup-icon-box {
    width: 56px;
    height: 56px;
    background: white;
    border-radius: 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 14px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    position: relative;
    z-index: 1;
}

.popup-icon-box svg { width: 28px; height: 28px; color: #10b981; }

.popup-header h2 {
    color: white;
    font-size: 1.35rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.popup-header p {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.85rem;
}

.popup-body {
    padding: 24px;
}

.popup-input-row {
    display: flex;
    align-items: stretch;
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.2s;
    background: #f8fafc;
}

.popup-input-row:focus-within {
    border-color: #10b981;
    box-shadow: 0 0 0 4px rgba(16, 185, 129, 0.1);
    background: white;
}

.popup-input-icon {
    width: 44px;
    background: #f1f5f9;
    display: flex;
    align-items: center;
    justify-content: center;
    border-right: 2px solid #e2e8f0;
}
.popup-input-row:focus-within .popup-input-icon {
    background: #ecfdf5;
    border-right-color: #10b981;
}
.popup-input-icon svg { width: 18px; color: #64748b; }
.popup-input-row:focus-within .popup-input-icon svg { color: #10b981; }

.popup-input {
    flex: 1;
    border: none;
    outline: none;
    padding: 12px 14px;
    font-size: 0.95rem;
    color: #1e293b;
    background: transparent;
}

.popup-input::placeholder {
    color: #94a3b8 !important;
    opacity: 1;
}

.popup-btn-submit {
    width: 100%;
    margin-top: 20px;
    padding: 14px;
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    color: white;
    border: none;
    border-radius: 12px;
    font-size: 1rem;
    font-weight: 700;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.25);
    transition: all 0.3s;
}

.popup-btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(16, 185, 129, 0.35);
}

@media (max-width: 640px) {
    .popup-card { max-width: 90%; }
    .tracking-header h1 { font-size: 1.6rem; }
}

/* ─── Popup body padding ───────────────────────────────── */
.popup-body {
    padding: 24px;
}

/* ─── Input row & icon prefix ──────────────────────────── */
.popup-input-row {
    border: 2px solid #e2e8f0;
    border-radius: 12px;
    display: flex;
    overflow: hidden;
    background: #f8fafc;
    transition: border-color 0.2s;
}
.popup-input-row:focus-within { border-color: #10b981; }
.popup-input-row.row-error    { border-color: #ef4444 !important; animation: input-shake 0.4s ease; }
.popup-input-row.row-success  { border-color: #10b981 !important; background: #f0fdf4; }

.popup-input-icon {
    background: #10b981;
    padding: 0 12px;
    display: flex;
    align-items: center;
    flex-shrink: 0;
    transition: background 0.2s;
}
.popup-input-row.row-error   .popup-input-icon { background: #ef4444; }
.popup-input-row.row-success .popup-input-icon { background: #059669; }

.popup-input {
    width: 100%;
    padding: 12px;
    outline: none;
    background: transparent;
    color: #1e293b;
    font-weight: 600;
    font-size: 14px;
    letter-spacing: 0.5px;
    border: none;
}
.popup-input::placeholder { font-weight: 400; color: #94a3b8; letter-spacing: 0; }

/* ─── Error message ────────────────────────────────────── */
.lacak-error-msg         { font-size: 12px; color: #dc2626; margin-top: 6px; padding-left: 2px; min-height: 18px; }
.lacak-error-msg.hidden  { display: none; }
.lacak-error-msg.visible { display: block; }

/* ─── Tombol submit ────────────────────────────────────── */
.btn-lacak-submit {
    width: 100%;
    margin-top: 20px;
    padding: 13px 20px;
    background: linear-gradient(to right, #10b981, #059669);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: transform 0.15s, box-shadow 0.2s, background 0.25s;
}
.btn-lacak-submit:hover:not(:disabled) {
    transform: translateY(-1px);
    box-shadow: 0 6px 20px rgba(5, 150, 105, 0.35);
}

/* Loading */
.btn-lacak-submit.btn-loading {
    background: #6b7280 !important;
    cursor: wait;
    transform: scale(0.98);
    box-shadow: none;
}

/* Sukses */
.btn-lacak-submit.btn-success {
    background: linear-gradient(to right, #059669, #047857) !important;
    box-shadow: 0 4px 16px rgba(5, 150, 105, 0.4) !important;
    transform: scale(1.01);
    cursor: default;
}
.btn-lacak-submit.btn-success svg {
    animation: pop-in 0.3s cubic-bezier(0.34, 1.56, 0.64, 1);
}

@keyframes pop-in {
    from { transform: scale(0) rotate(-30deg); opacity: 0; }
    to   { transform: scale(1) rotate(0);      opacity: 1; }
}

@keyframes input-shake {
    0%, 100% { transform: translateX(0); }
    20%       { transform: translateX(-5px); }
    40%       { transform: translateX(5px); }
    60%       { transform: translateX(-3px); }
    80%       { transform: translateX(3px); }
}

/* ─── Modal "Kode Tidak Ditemukan" ────────────────────── */
.lacak-notfound-modal {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.6);
    z-index: 99999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.2s;
    backdrop-filter: blur(3px);
}
.lacak-notfound-modal.visible { opacity: 1; }

.lacak-notfound-box {
    background: #fff;
    border-radius: 20px;
    padding: 32px 28px;
    max-width: 360px;
    width: 100%;
    text-align: center;
    box-shadow: 0 24px 64px rgba(0, 0, 0, 0.22);
    animation: slide-up-modal 0.25s ease;
}

@keyframes slide-up-modal {
    from { transform: translateY(16px) scale(0.97); opacity: 0; }
    to   { transform: translateY(0)    scale(1);    opacity: 1; }
}

.lacak-notfound-icon {
    width: 60px; height: 60px;
    background: #fef2f2;
    border-radius: 50%;
    display: flex; align-items: center; justify-content: center;
    margin: 0 auto 16px;
}
.lacak-notfound-icon svg { width: 30px; height: 30px; stroke: #ef4444; }

.lacak-notfound-title { font-size: 18px; font-weight: 700; color: #111827; margin-bottom: 8px; }
.lacak-notfound-desc  { font-size: 14px; color: #6b7280; line-height: 1.65; margin-bottom: 24px; }

.lacak-notfound-btn {
    width: 100%;
    padding: 12px 24px;
    background: #059669;
    color: #fff;
    border: none;
    border-radius: 10px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.15s;
}
.lacak-notfound-btn:hover { background: #047857; transform: translateY(-1px); }