* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    -webkit-tap-highlight-color: transparent;
}

body, html {
    width: 100%;
    height: 100%;
    background-color: #f4f7fb;
    font-family: 'Montserrat', sans-serif;
    color: #333;
}

h1, h2, h3 {
    font-family: 'Montserrat Alternates', sans-serif;
    font-weight: 700;
}

.header {
    display: none;
}

.main-content {
    padding: 2rem 1rem;
    width: 100%;
    max-width: 500px;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
}

.brand-logo {
    width: 190px;
    height: auto;
    margin-bottom: 2rem;
    filter: drop-shadow(0 4px 10px rgba(0, 102, 204, 0.2));
}

.card {
    background: #fff;
    border-radius: 20px;
    padding: 2.5rem 1.8rem;
    box-shadow: 0 12px 40px rgba(0, 0, 0, 0.08);
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    width: 100%;
    animation: fadeIn 0.4s ease;
}

.hidden {
    display: none !important;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.title {
    text-align: center;
    font-size: 1.5rem;
    color: #1a1a1a;
}

.subtitle {
    text-align: center;
    font-size: 0.9rem;
    color: #666;
    line-height: 1.5;
}

.input-group {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.search-input { display: none; } /* superseded by input-wrapper */

/* ── Checkout-style input ── */
.input-label {
    display: block;
    font-size: 10px;
    font-weight: 700;
    color: #9ca3af;
    text-transform: uppercase;
    margin-bottom: 8px;
    letter-spacing: 1px;
}

.input-wrapper {
    display: flex;
    border: 2px solid #f0f0f0;
    border-radius: 16px;
    overflow: hidden;
    transition: 0.2s;
    background: #fff;
}

.input-wrapper:focus-within {
    border-color: #0066CC;
    box-shadow: 0 0 0 4px rgba(0, 102, 204, 0.05);
}

.dial-code {
    background: #f9fafb;
    padding: 14px 18px;
    font-weight: 700;
    color: #4b5563;
    border-right: 2px solid #f0f0f0;
    font-family: 'Montserrat', sans-serif;
    font-size: 0.95rem;
}

.phone-input {
    width: 100%;
    border: none;
    outline: none;
    padding: 14px;
    font-size: 18px;
    font-weight: 400;
    color: #111827;
    font-family: 'Montserrat', sans-serif;
    background: transparent;
}

.op-badge {
    position: absolute;
    right: 15px;
    top: 50%;
    transform: translateY(-50%);
    height: 28px;
    width: 28px;
    opacity: 0;
    transition: 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    pointer-events: none;
    border-radius: 50%;
    border: 1px solid #f0f0f0;
    background: #fff;
    padding: 1px;
    object-fit: contain;
}

.op-badge.visible {
    opacity: 1;
    transform: translateY(-50%) scale(1.1);
}

/* ── Dashed border + shimmer button ── */
.btn-outer-border {
    border: 2px dashed #0066CC;
    border-radius: 20px;
    padding: 5px;
}

.primary-btn {
    background-color: #0066CC;
    color: #fff;
    border: none;
    border-radius: 14px;
    padding: 1.1rem;
    font-size: 1.05rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    cursor: pointer;
    width: 100%;
    position: relative;
    overflow: hidden;
    transition: background-color 0.2s, transform 0.1s;
}

.primary-btn::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 80px;
    height: 100%;
    background: linear-gradient(105deg, transparent 0%, rgba(255, 255, 255, 0.3) 50%, transparent 100%);
    transform: translateX(-150px) skewX(-15deg);
    animation: shimmer 4s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-150px) skewX(-15deg); }
    15% { transform: translateX(500px) skewX(-15deg); }
    100% { transform: translateX(500px) skewX(-15deg); }
}

.primary-btn:active {
    transform: scale(0.98);
    background-color: #0052a3;
}

.primary-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.secondary-btn {
    background-color: #f0f0f0;
    color: #333;
    border: none;
    border-radius: 12px;
    padding: 1rem;
    font-size: 1rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
    margin-top: 1rem;
}

.secondary-btn:hover {
    background-color: #e0e0e0;
}

.error-msg {
    color: #d32f2f;
    font-size: 0.85rem;
    text-align: center;
    font-weight: 500;
    min-height: 20px;
}

.support-link-container {
    text-align: center;
    font-size: 0.85rem;
    color: #666;
    margin-top: 0.5rem;
}

.support-link {
    color: #0066CC;
    font-weight: 600;
    text-decoration: none;
}

.support-link:hover {
    text-decoration: underline;
}

/* Details Box */
.details-box {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-bottom: 1px solid #e2e8f0;
    padding-bottom: 0.5rem;
}

.detail-row:last-of-type {
    border-bottom: none;
    padding-bottom: 0;
}

.detail-label {
    font-size: 0.85rem;
    font-weight: 600;
    color: #64748b;
}

.detail-value {
    font-size: 0.95rem;
    font-weight: 700;
    color: #0f172a;
    text-align: right;
}

.code-highlight {
    margin-top: 1rem;
    background: #EEF4FF;
    border: 2px dashed #0066CC;
    border-radius: 12px;
    padding: 1.2rem;
    text-align: center;
}

.code-label {
    display: block;
    font-size: 0.8rem;
    font-weight: 700;
    color: #0066CC;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.5rem;
}

.code-value-box {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 1rem;
}

.code-val {
    font-family: monospace;
    font-size: 2rem;
    font-weight: 900;
    color: #1e293b;
    letter-spacing: 2px;
}

.copy-btn {
    background: #0066CC;
    color: #fff;
    border: none;
    border-radius: 8px;
    padding: 0.5rem 1rem;
    font-family: 'Montserrat', sans-serif;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: background 0.2s;
}

.copy-btn:hover {
    background: #0055b3;
}

/* Status Pills */
.details-header {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
}

.status-pill {
    padding: 0.35rem 1rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    display: inline-block;
}

.status-pill.active {
    background: rgba(9, 146, 80, 0.1);
    color: #099250;
    border: 1px solid rgba(9, 146, 80, 0.3);
}

.status-pill.expired {
    background: rgba(211, 47, 47, 0.1);
    color: #d32f2f;
    border: 1px solid rgba(211, 47, 47, 0.3);
}

/* Blurred state for expired code */
.code-blurred {
    filter: blur(5px);
    user-select: none;
    pointer-events: none;
}
