/* Travel Package Builder - Frontend Styles */

/* Wrapper */
.tpb-wrapper {
    max-width: 1200px;
    margin: 40px auto;
    padding: 20px;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

/* Progress Bar */
.tpb-progress-bar {
    display: flex;
    justify-content: space-between;
    margin-bottom: 40px;
    padding: 20px 0;
    border-bottom: 2px solid #ecf0f1;
}

.tpb-step {
    display: flex;
    flex-direction: column;
    align-items: center;
    flex: 1;
    position: relative;
    cursor: default;
}

.tpb-step::after {
    content: '';
    position: absolute;
    top: 20px;
    left: 50%;
    width: 100%;
    height: 2px;
    background: #ecf0f1;
    z-index: -1;
}

.tpb-step:last-child::after {
    display: none;
}

.tpb-step .step-number {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #ecf0f1;
    color: #7f8c8d;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    margin-bottom: 8px;
    transition: all 0.3s ease;
}

.tpb-step.active .step-number {
    background: #3498db;
    color: white;
}

.tpb-step.completed .step-number {
    background: #27ae60;
    color: white;
}

.tpb-step .step-label {
    font-size: 12px;
    color: #7f8c8d;
    text-align: center;
}

.tpb-step.active .step-label {
    color: #2c3e50;
    font-weight: bold;
}

/* Form Container */
.tpb-form-container {
    padding: 20px 0;
}

.tpb-form-step {
    display: none;
}

.tpb-form-step.active {
    display: block;
    animation: fadeIn 0.3s ease;
}

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

.tpb-form-step h2 {
    color: #2c3e50;
    margin-bottom: 30px;
    font-size: 28px;
}

.tpb-form-step h3 {
    color: #34495e;
    margin: 30px 0 20px;
    font-size: 22px;
}

.tpb-form-step h4 {
    color: #34495e;
    margin: 25px 0 15px;
    font-size: 18px;
}

/* Field Groups */
.tpb-field-group {
    margin-bottom: 25px;
}

.tpb-field-group label {
    display: block;
    margin-bottom: 8px;
    color: #2c3e50;
    font-weight: 600;
}

.tpb-field-group select,
.tpb-field-group input[type="text"],
.tpb-field-group input[type="email"],
.tpb-field-group input[type="tel"],
.tpb-field-group input[type="number"] {
    width: 100%;
    padding: 12px;
    border: 1px solid #bdc3c7;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s ease;
}

.tpb-field-group select:focus,
.tpb-field-group input:focus {
    outline: none;
    border-color: #3498db;
}

/* Radio Groups */
.tpb-radio-group {
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
}

.tpb-radio-label {
    flex: 1;
    min-width: 150px;
    padding: 15px;
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
}

.tpb-radio-label:hover {
    border-color: #3498db;
    background: #f8f9fa;
}

.tpb-radio-label input[type="radio"] {
    margin-right: 10px;
}

.tpb-radio-label input[type="radio"]:checked + span {
    font-weight: bold;
    color: #3498db;
}

/* Destination Cards */
.tpb-destinations-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.tpb-destination-card {
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.tpb-destination-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transform: translateY(-2px);
}

.tpb-destination-card label {
    display: block;
    cursor: pointer;
    padding: 0;
}

.tpb-destination-card input[type="checkbox"] {
    margin: 15px;
}

.tpb-destination-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.tpb-destination-card h4 {
    margin: 15px;
    color: #2c3e50;
}

.tpb-destination-card p {
    margin: 0 15px 15px;
    color: #7f8c8d;
    font-size: 14px;
}

/* Hotel Cards */
.tpb-hotels-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.tpb-hotel-card {
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    overflow: hidden;
    transition: all 0.3s ease;
}

.tpb-hotel-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.tpb-hotel-card label {
    display: block;
    cursor: pointer;
    padding: 0;
}

.tpb-hotel-card input[type="radio"] {
    margin: 15px;
}

.tpb-hotel-card img {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.tpb-hotel-card h5 {
    margin: 15px;
    color: #2c3e50;
}

.tpb-hotel-card .tpb-hotel-address {
    margin: 0 15px;
    color: #7f8c8d;
    font-size: 12px;
}

.tpb-hotel-card p {
    margin: 10px 15px 15px;
    color: #7f8c8d;
    font-size: 14px;
}

/* Tours Grid */
.tpb-tours-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.tpb-tour-card {
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}

.tpb-tour-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.tpb-tour-card label {
    display: block;
    cursor: pointer;
}

.tpb-tour-card input[type="checkbox"] {
    margin-right: 10px;
}

.tpb-tour-card img {
    width: 100%;
    height: 150px;
    object-fit: cover;
    border-radius: 4px;
    margin-bottom: 10px;
}

.tpb-tour-card h5 {
    margin: 10px 0;
    color: #2c3e50;
}

.tpb-tour-meta {
    margin: 5px 0;
    color: #7f8c8d;
    font-size: 13px;
}

.tpb-tour-card p {
    margin: 10px 0 0;
    color: #7f8c8d;
    font-size: 14px;
}

/* Transport Grid */
.tpb-transport-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.tpb-transport-card {
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}

.tpb-transport-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.tpb-transport-card label {
    display: block;
    cursor: pointer;
}

.tpb-transport-card input[type="checkbox"] {
    margin-right: 10px;
}

.tpb-transport-card h5 {
    margin: 10px 0;
    color: #2c3e50;
}

.tpb-transport-meta {
    margin: 5px 0;
    color: #7f8c8d;
    font-size: 13px;
}

/* Meals Grid */
.tpb-meals-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
    margin: 20px 0;
}

.tpb-meal-card {
    border: 2px solid #ecf0f1;
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}

.tpb-meal-card:hover {
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
}

.tpb-meal-card label {
    display: block;
    cursor: pointer;
}

.tpb-meal-card input[type="checkbox"] {
    margin-right: 10px;
}

.tpb-meal-card h5 {
    margin: 10px 0;
    color: #2c3e50;
}

.tpb-meal-meta {
    margin: 5px 0;
    color: #7f8c8d;
    font-size: 13px;
}

/* Summary */
.tpb-summary {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 8px;
    margin: 20px 0;
}

.tpb-summary-section {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #ecf0f1;
}

.tpb-summary-section:last-child {
    border-bottom: none;
}

.tpb-summary-section h4 {
    color: #2c3e50;
    margin: 0 0 10px;
}

.tpb-summary-section ul {
    list-style: disc;
    margin-left: 20px;
}

/* Navigation */
.tpb-form-navigation {
    display: flex;
    justify-content: space-between;
    margin-top: 40px;
    padding-top: 20px;
    border-top: 2px solid #ecf0f1;
}

.tpb-button {
    padding: 12px 30px;
    background: #3498db;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.3s ease;
}

.tpb-button:hover {
    background: #2980b9;
}

.tpb-button-secondary {
    padding: 10px 20px;
    background: #95a5a6;
    color: white;
    border: none;
    border-radius: 4px;
    font-size: 14px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.tpb-button-secondary:hover {
    background: #7f8c8d;
}

/* Loading Overlay */
#tpb-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.7);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.tpb-loading-content {
    background: white;
    padding: 40px;
    border-radius: 8px;
    text-align: center;
}

.tpb-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid #ecf0f1;
    border-top: 5px solid #3498db;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

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

/* Messages */
.tpb-loading {
    padding: 20px;
    text-align: center;
    color: #7f8c8d;
}

.tpb-error {
    padding: 15px;
    background: #e74c3c;
    color: white;
    border-radius: 4px;
}

.tpb-notice {
    padding: 15px;
    background: #f39c12;
    color: white;
    border-radius: 4px;
}

/* Responsive */
@media (max-width: 768px) {
    .tpb-progress-bar {
        flex-wrap: wrap;
    }
    
    .tpb-step {
        flex: 0 0 50%;
        margin-bottom: 20px;
    }
    
    .tpb-step .step-label {
        font-size: 11px;
    }
    
    .tpb-destinations-grid,
    .tpb-hotels-grid,
    .tpb-tours-grid,
    .tpb-transport-grid,
    .tpb-meals-grid {
        grid-template-columns: 1fr;
    }
    
    .tpb-radio-group {
        flex-direction: column;
    }
}
