/* FedEx Tracker Plugin Styles */

.fedex-tracker-container {
    max-width: 1000px;
    margin: 30px auto;
}

.fedex-search-section {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
}

.fedex-input-group {
    display: flex;
    gap: 10px;
}

.fedex-input-stacked {
    flex-wrap: wrap;
}

.fedex-input-group input[type="text"],
.fedex-input-group input[type="email"] {
    flex: 1;
    min-width: 200px;
    padding: 15px 20px;
    font-size: 16px;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    transition: border-color 0.3s;
    max-width: none;
    height: auto;
}

.fedex-input-group input[type="text"]:focus,
.fedex-input-group input[type="email"]:focus {
    outline: none;
    border-color: #667eea;
}

.fedex-input-group button {
    padding: 15px 30px;
    background-color: #0019ff;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: transform 0.2s, box-shadow 0.2s;
    min-width: 150px;
}

.fedex-input-group button:hover {
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(102, 126, 234, 0.4);
}

.fedex-input-group button:active {
    transform: translateY(0);
}

.fedex-input-group button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.fedex-loader {
    border: 3px solid rgba(255, 255, 255, 0.3);
    border-top: 3px solid white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    animation: fedex-spin 1s linear infinite;
    display: inline-block;
}

@keyframes fedex-spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.fedex-error-message {
    background: #fee;
    color: #c33;
    padding: 15px 20px;
    border-radius: 8px;
    margin-bottom: 20px;
    border-left: 4px solid #c33;
}

.fedex-card {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 20px;
}

.fedex-card h2 {
    color: #667eea;
    margin-bottom: 20px;
    margin-top: 0;
    font-size: 1.5em;
    border-bottom: 2px solid #f0f0f0;
    padding-bottom: 10px;
}

.fedex-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 15px;
}

.fedex-info-item {
    display: flex;
    flex-direction: column;
    gap: 5px;
}

.fedex-label {
    font-weight: 600;
    color: #666;
    font-size: 0.9em;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.fedex-value {
    font-size: 1.1em;
    color: #333;
}

.fedex-status-badge {
    display: inline-block;
    padding: 8px 16px;
    background: #4caf50;
    color: white;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.95em;
    max-width: fit-content;
}

/* Packing State Styles */
.fedex-packing-state {
    margin-bottom: 20px;
}

.fedex-packing-card {
    text-align: center;
    padding: 40px 25px;
}

.fedex-packing-card h2 {
    border-bottom: none;
    color: #333;
    font-size: 1.8em;
    margin-bottom: 15px;
}

.fedex-packing-icon {
    font-size: 4em;
    margin-bottom: 20px;
    animation: fedex-bounce 2s ease-in-out infinite;
}

@keyframes fedex-bounce {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.fedex-packing-subtext {
    color: #888;
    font-size: 0.95em;
    margin-top: 10px;
}

.fedex-packing-progress {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 30px;
    flex-wrap: wrap;
}

.fedex-progress-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 10px 20px;
    position: relative;
}

.fedex-progress-step:not(:last-child)::after {
    content: '';
    position: absolute;
    right: -10px;
    top: 50%;
    transform: translateY(-50%);
    width: 20px;
    height: 2px;
    background: #e0e0e0;
}

.fedex-progress-step.completed:not(:last-child)::after {
    background: #4caf50;
}

.fedex-step-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.2em;
    background: #f0f0f0;
    color: #999;
}

.fedex-progress-step.completed .fedex-step-icon {
    background: #4caf50;
    color: white;
}

.fedex-progress-step.active .fedex-step-icon {
    background: #667eea;
    color: white;
    animation: fedex-pulse 1.5s ease-in-out infinite;
}

.fedex-progress-step span {
    font-size: 0.85em;
    color: #666;
    font-weight: 500;
}

.fedex-progress-step.completed span {
    color: #4caf50;
}

.fedex-progress-step.active span {
    color: #667eea;
    font-weight: 600;
}

/* Timeline Styles */
.fedex-timeline {
    position: relative;
    padding-left: 30px;
}

.fedex-timeline::before {
    content: '';
    position: absolute;
    left: 8px;
    top: 0;
    bottom: 0;
    width: 2px;
    background: #e0e0e0;
}

.fedex-timeline-item {
    position: relative;
    padding: 15px 0;
    padding-left: 25px;
}

.fedex-timeline-item::before {
    content: '';
    position: absolute;
    left: -26.5px;
    top: 20px;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ffffff;
    border: 3px solid white;
    box-shadow: 0 0 0 2px #667eea;
}

.fedex-timeline-item:first-child::before {
    background: #4caf50;
    box-shadow: 0 0 0 2px #4caf50;
}

.fedex-timeline-date {
    font-weight: 600;
    color: #667eea;
    font-size: 0.95em;
    margin-bottom: 5px;
}

.fedex-timeline-description {
    color: #333;
    font-size: 1em;
    margin-bottom: 3px;
}

.fedex-timeline-location {
    color: #999;
    font-size: 0.9em;
}

/* Responsive */
@media (max-width: 768px) {
    .fedex-input-group {
        flex-direction: column;
    }

    .fedex-input-group input[type="text"],
    .fedex-input-group input[type="email"] {
        min-width: 100%;
    }

    .fedex-input-group button {
        width: 100%;
    }

    .fedex-info-grid {
        grid-template-columns: 1fr;
    }

}
