/* =================================================================
   Live Package Tracking - Complete Stylesheet
   ================================================================= */

/* CSS Variables */
:root {
    --primary-blue: #1565C0;
    --primary-dark: #0d47a1;
    --accent-blue: #4da6ff;
    --text-dark: #0f1c2e;
    --text-medium: #3a4553;
    --text-light: #5c6575;
    --bg-light: #f8fafb;
    --bg-white: #ffffff;
    --border-light: #e5e7eb;
    --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
    --shadow-md: 0 4px 20px rgba(0,0,0,0.08);
    --shadow-lg: 0 10px 40px rgba(0,0,0,0.12);
    --gradient-primary: linear-gradient(135deg, #1565C0 0%, #0d47a1 100%);
    --gradient-hero: linear-gradient(135deg, #003366 0%, #004B87 100%);
    --gradient-dark: linear-gradient(135deg, #0f1c2e 0%, #1a2d4a 100%);
    --radius-sm: 8px;
    --radius-md: 12px;
    --radius-lg: 16px;
    --radius-xl: 24px;
}

/* Reset */
*, *::before, *::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--bg-white);
}

a {
    color: inherit;
    text-decoration: none;
}

img {
    max-width: 100%;
    height: auto;
}

button {
    font-family: inherit;
    cursor: pointer;
    border: none;
    background: none;
}

/* =================================================================
   SITE HEADER
   ================================================================= */

.site-header {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background: rgba(255,255,255,0.98);
    backdrop-filter: blur(10px);
    box-shadow: 0 2px 20px rgba(0,0,0,0.06);
}

.header-content {
    max-width: 1200px;
    margin: 0 auto;
    padding: 12px 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.site-header .logo {
    display: flex;
    align-items: center;
    gap: 12px;
    text-decoration: none;
}

.site-header .logo img {
    height: 36px;
    width: auto;
}

.site-header .logo span {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
}

.header-nav {
    display: flex;
    gap: 32px;
    align-items: center;
}

.header-nav a {
    color: var(--text-light);
    font-size: 15px;
    font-weight: 500;
    transition: color 0.2s;
}

.header-nav a:hover {
    color: var(--primary-blue);
}

@media (max-width: 768px) {
    .header-nav {
        display: none;
    }
}

/* =================================================================
   HERO SECTION
   ================================================================= */

.hero-section {
    position: relative;
    min-height: 100vh;
    padding: 100px 24px 60px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.hero-background {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: var(--gradient-hero);
    z-index: -1;
}

.hero-container {
    max-width: 1100px;
    margin: 0 auto;
    width: 100%;
}

.hero-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 40px;
    align-items: start;
}

@media (max-width: 900px) {
    .hero-grid {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

/* Tracking Card */
.tracking-card {
    background: var(--bg-white);
    border-radius: var(--radius-xl);
    padding: 32px;
    box-shadow: var(--shadow-lg);
}

.tracking-header {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 24px;
}

.tracking-icon {
    width: 56px;
    height: 56px;
    background: var(--gradient-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
}

.tracking-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
}

.tracking-subtitle {
    font-size: 14px;
    color: var(--text-light);
    margin: 4px 0 0;
}

.tracking-form {
    margin-bottom: 20px;
}

.input-group {
    display: flex;
    gap: 12px;
}

.input-group input {
    flex: 1;
    padding: 14px 18px;
    font-size: 16px;
    border: 2px solid var(--border-light);
    border-radius: var(--radius-md);
    outline: none;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.input-group input:focus {
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(21,101,192,0.1);
}

.input-group input::placeholder {
    color: #9ca3af;
}

.track-btn {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 24px;
    background: var(--gradient-primary);
    color: white;
    font-size: 16px;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: transform 0.2s, box-shadow 0.2s;
}

.track-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(21,101,192,0.3);
}

.carrier-logos {
    display: flex;
    gap: 24px;
    align-items: center;
    justify-content: center;
    padding-top: 16px;
    border-top: 1px solid var(--border-light);
}

.carrier-logos img {
    height: 20px;
    width: 60px;
    object-fit: contain;
    opacity: 0.7;
    transition: opacity 0.2s;
}

.carrier-logos img:hover {
    opacity: 1;
}

/* Samples Card */
.samples-card {
    background: var(--bg-white);
    border-radius: var(--radius-xl);
    padding: 28px;
    box-shadow: var(--shadow-lg);
    min-height: 400px;
}

.samples-header {
    margin-bottom: 20px;
}

.samples-header h2 {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 4px;
}

.samples-header p {
    font-size: 14px;
    color: var(--text-light);
    margin: 0;
}

.samples-table {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.samples-row {
    display: grid;
    grid-template-columns: 1fr 1.5fr;
    gap: 16px;
    padding: 12px 16px;
    background: var(--bg-light);
    border-radius: var(--radius-sm);
    font-size: 14px;
    transition: background 0.2s;
}

.samples-row:hover:not(.header) {
    background: #e3f2fd;
}

.samples-row.header {
    background: var(--gradient-primary);
    color: white;
    font-weight: 600;
}

.samples-row span:last-child {
    font-family: 'Courier New', monospace;
    font-size: 13px;
    color: var(--text-medium);
}

.samples-row.header span:last-child {
    color: white;
    font-family: inherit;
}

/* Results View */
.results-view {
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    padding-bottom: 16px;
    border-bottom: 1px solid var(--border-light);
}

.results-carrier {
    display: flex;
    align-items: center;
    gap: 12px;
}

.results-carrier img {
    width: 48px;
    height: 48px;
    object-fit: contain;
}

.results-carrier h2 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0;
}

.results-carrier p {
    font-size: 13px;
    color: var(--text-light);
    margin: 4px 0 0;
    font-family: monospace;
}

.status-badge {
    display: inline-block;
    padding: 6px 14px;
    font-size: 13px;
    font-weight: 600;
    border-radius: 20px;
}

.results-delivery {
    background: var(--bg-light);
    padding: 16px;
    border-radius: var(--radius-md);
    margin-bottom: 20px;
}

.delivery-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.delivery-label {
    font-size: 14px;
    color: var(--text-light);
}

.delivery-date {
    font-size: 16px;
    font-weight: 600;
    color: var(--text-dark);
}

.results-timeline {
    max-height: 250px;
    overflow-y: auto;
    padding-right: 8px;
}

.timeline-event {
    display: flex;
    gap: 16px;
    padding: 12px 0;
    border-left: 2px solid var(--border-light);
    margin-left: 8px;
    padding-left: 20px;
    position: relative;
}

.timeline-event.current {
    border-left-color: var(--primary-blue);
}

.timeline-marker {
    position: absolute;
    left: -6px;
    top: 16px;
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: #d1d5db;
}

.timeline-content {
    flex: 1;
}

.timeline-status {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-dark);
    margin: 0 0 4px;
}

.timeline-meta {
    font-size: 12px;
    color: var(--text-light);
    margin: 0;
}

.timeline-empty {
    text-align: center;
    padding: 30px;
    color: var(--text-light);
}

.timeline-empty p {
    margin: 8px 0;
}

.track-another-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    width: 100%;
    padding: 14px;
    margin-top: 20px;
    background: var(--bg-light);
    color: var(--text-dark);
    font-size: 14px;
    font-weight: 600;
    border-radius: var(--radius-md);
    transition: background 0.2s;
}

.track-another-btn:hover {
    background: #e5e7eb;
}

/* Loading View */
.loading-view {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 350px;
    gap: 20px;
}

.loading-spinner {
    width: 48px;
    height: 48px;
    border: 4px solid var(--border-light);
    border-top-color: var(--primary-blue);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-text {
    font-size: 16px;
    color: var(--text-medium);
    margin: 0;
}

.loading-progress {
    width: 200px;
    height: 4px;
    background: var(--border-light);
    border-radius: 2px;
    overflow: hidden;
}

.loading-bar {
    height: 100%;
    background: var(--gradient-primary);
    width: 0%;
    transition: width 0.3s ease;
}

/* Scroll Indicator */
.scroll-indicator {
    position: absolute;
    bottom: 30px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    cursor: pointer;
}

.scroll-text {
    font-size: 14px;
    color: rgba(255,255,255,0.9);
    font-weight: 500;
}

.scroll-arrow {
    width: 40px;
    height: 40px;
    background: rgba(255,255,255,0.95);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    animation: bounce 2s infinite;
}

.scroll-arrow svg {
    stroke: var(--text-dark);
}

@keyframes bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(8px); }
}

/* =================================================================
   SECTION STYLES (COMMON)
   ================================================================= */

.section-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.section-header {
    text-align: center;
    margin-bottom: 50px;
}

.section-header.light .section-tag,
.section-header.light .section-title,
.section-header.light .section-subtitle {
    color: white;
}

.section-header.light .section-subtitle {
    opacity: 0.8;
}

.section-tag {
    display: inline-block;
    padding: 6px 16px;
    background: rgba(21,101,192,0.1);
    color: var(--primary-blue);
    font-size: 13px;
    font-weight: 600;
    border-radius: 20px;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.section-header.light .section-tag {
    background: rgba(255,255,255,0.15);
}

.section-title {
    font-size: 36px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 12px;
}

.section-subtitle {
    font-size: 18px;
    color: var(--text-light);
    margin: 0;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

@media (max-width: 768px) {
    .section-title {
        font-size: 28px;
    }
    .section-subtitle {
        font-size: 16px;
    }
}

/* =================================================================
   INTRO SECTION
   ================================================================= */

.intro-section {
    padding: 80px 0;
    background: linear-gradient(to bottom, var(--bg-white), var(--bg-light));
}

.intro-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 30px;
}

@media (max-width: 1024px) {
    .intro-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .intro-grid {
        grid-template-columns: 1fr;
    }
}

.intro-card {
    background: var(--bg-white);
    padding: 30px;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-md);
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

.intro-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.intro-icon {
    width: 56px;
    height: 56px;
    background: var(--gradient-primary);
    border-radius: var(--radius-md);
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 20px;
    color: white;
}

.intro-card h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 12px;
}

.intro-card p {
    font-size: 14px;
    color: var(--text-light);
    margin: 0;
    line-height: 1.6;
}

/* =================================================================
   CARRIERS SECTION
   ================================================================= */

.carriers-section {
    padding: 80px 0;
    background: var(--bg-white);
}

.carriers-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

@media (max-width: 900px) {
    .carriers-grid {
        grid-template-columns: 1fr;
    }
}

.carrier-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: transform 0.3s, box-shadow 0.3s;
    cursor: pointer;
}

.carrier-card:hover {
    transform: translateY(-8px);
    box-shadow: var(--shadow-lg);
}

.carrier-card-image {
    height: 140px;
    background: var(--bg-light);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 30px;
}

.carrier-card-image img {
    max-height: 60px;
    max-width: 150px;
    object-fit: contain;
}

.carrier-card-content {
    padding: 24px;
}

.carrier-card-content h3 {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 12px;
}

.carrier-card-content p {
    font-size: 14px;
    color: var(--text-light);
    margin: 0 0 16px;
    line-height: 1.6;
}

.carrier-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.carrier-tags span {
    padding: 4px 12px;
    background: var(--bg-light);
    color: var(--text-medium);
    font-size: 12px;
    font-weight: 500;
    border-radius: 20px;
}

/* =================================================================
   ARTICLES SECTION
   ================================================================= */

.articles-section {
    padding: 80px 0;
    background: linear-gradient(to bottom, var(--bg-light), var(--bg-white));
}

.articles-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

@media (max-width: 1024px) {
    .articles-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .articles-grid {
        grid-template-columns: 1fr;
    }
}

.article-card {
    background: var(--bg-white);
    border-radius: var(--radius-lg);
    overflow: hidden;
    box-shadow: var(--shadow-md);
    transition: transform 0.3s, box-shadow 0.3s;
    text-decoration: none;
}

.article-card:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-lg);
}

.article-image {
    height: 180px;
    background-size: cover;
    background-position: center;
    position: relative;
}

.article-category {
    position: absolute;
    top: 16px;
    left: 16px;
    padding: 4px 12px;
    background: var(--gradient-primary);
    color: white;
    font-size: 11px;
    font-weight: 600;
    border-radius: 20px;
    text-transform: uppercase;
}

.article-content {
    padding: 20px;
}

.article-content h3 {
    font-size: 18px;
    font-weight: 700;
    color: var(--text-dark);
    margin: 0 0 10px;
    line-height: 1.3;
}

.article-content p {
    font-size: 14px;
    color: var(--text-light);
    margin: 0 0 12px;
    line-height: 1.5;
}

.article-date {
    font-size: 12px;
    color: var(--text-light);
    display: flex;
    align-items: center;
    gap: 6px;
}

/* =================================================================
   FEATURES SECTION (DARK)
   ================================================================= */

.features-section {
    padding: 80px 0;
    background: var(--gradient-dark);
}

.features-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
}

@media (max-width: 1024px) {
    .features-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 600px) {
    .features-grid {
        grid-template-columns: 1fr;
    }
}

.feature-card {
    background: rgba(255,255,255,0.08);
    padding: 30px;
    border-radius: var(--radius-lg);
    transition: background 0.3s;
}

.feature-card:hover {
    background: rgba(255,255,255,0.12);
}

.feature-icon {
    width: 48px;
    height: 48px;
    background: var(--gradient-primary);
    border-radius: var(--radius-sm);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
    color: white;
}

.feature-card h3 {
    font-size: 18px;
    font-weight: 700;
    color: white;
    margin: 0 0 10px;
}

.feature-card p {
    font-size: 14px;
    color: rgba(255,255,255,0.7);
    margin: 0;
    line-height: 1.6;
}

/* =================================================================
   CTA SECTION
   ================================================================= */

.cta-section {
    padding: 80px 0;
    background: var(--bg-white);
}

.cta-box {
    background: var(--gradient-primary);
    padding: 60px 40px;
    border-radius: var(--radius-xl);
    text-align: center;
    box-shadow: 0 20px 60px rgba(21,101,192,0.3);
}

.cta-box h2 {
    font-size: 32px;
    font-weight: 700;
    color: white;
    margin: 0 0 12px;
}

.cta-box p {
    font-size: 18px;
    color: rgba(255,255,255,0.9);
    margin: 0 0 30px;
}

.cta-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 16px 32px;
    background: white;
    color: var(--primary-blue);
    font-size: 16px;
    font-weight: 600;
    border-radius: 50px;
    transition: transform 0.2s, box-shadow 0.2s;
}

.cta-btn:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

@media (max-width: 768px) {
    .cta-box {
        padding: 40px 24px;
    }
    .cta-box h2 {
        font-size: 24px;
    }
    .cta-box p {
        font-size: 16px;
    }
}

/* =================================================================
   FOOTER
   ================================================================= */

.site-footer {
    background: var(--gradient-dark);
    padding: 60px 0 0;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 24px;
}

.footer-grid {
    display: grid;
    grid-template-columns: 2fr 1fr 1fr 1fr;
    gap: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

@media (max-width: 900px) {
    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 600px) {
    .footer-grid {
        grid-template-columns: 1fr;
    }
}

.footer-brand {
    max-width: 300px;
}

.footer-logo {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.footer-logo img {
    height: 32px;
    width: auto;
}

.footer-logo span {
    font-size: 18px;
    font-weight: 700;
    color: white;
}

.footer-brand p {
    font-size: 14px;
    color: rgba(255,255,255,0.7);
    margin: 0;
    line-height: 1.6;
}

.footer-links h4 {
    font-size: 16px;
    font-weight: 600;
    color: white;
    margin: 0 0 20px;
}

.footer-links a {
    display: block;
    font-size: 14px;
    color: rgba(255,255,255,0.7);
    margin-bottom: 12px;
    transition: color 0.2s;
}

.footer-links a:hover {
    color: white;
}

.footer-bottom {
    padding: 24px 0;
    text-align: center;
}

.footer-bottom p {
    font-size: 14px;
    color: rgba(255,255,255,0.5);
    margin: 0;
}

/* =================================================================
   UTILITY CLASSES
   ================================================================= */

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}
