/**
 * Bike Tours Plugin - Frontend Styles
 */

/* Variables */
:root {
    --btp-primary: #000000;
    --btp-primary-dark: #333333;
    --btp-secondary: #1A1A2E;
    --btp-text: #333333;
    --btp-text-light: #666666;
    --btp-border: #E0E0E0;
    --btp-bg-light: #F8F9FA;
    --btp-success: #28A745;
    --btp-error: #DC3545;
    --btp-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    --btp-shadow-lg: 0 4px 20px rgba(0, 0, 0, 0.15);
    --btp-radius: 8px;
    --btp-radius-lg: 12px;
}

/* Reset */
.btp-tour-wrapper * {
    box-sizing: border-box;
}

/* Container */
.btp-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Hero Section */
.btp-hero {
    position: relative;
    height: 400px;
    overflow: hidden;
    background: var(--btp-secondary);
}

.btp-hero-image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.btp-hero-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.btp-hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(to bottom, rgba(0,0,0,0.2), rgba(0,0,0,0.6));
}

.btp-hero-content {
    position: relative;
    height: 100%;
    display: flex;
    align-items: flex-end;
    padding-bottom: 40px;
    z-index: 1;
}

.btp-tour-title {
    color: #FFFFFF;
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 10px 0;
    line-height: 1.2;
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.btp-tour-subtitle {
    color: rgba(255,255,255,0.9);
    font-size: 1.2rem;
    margin: 0;
}

/* Main Content Layout */
.btp-main {
    padding: 40px 0 60px;
    background: #FFFFFF;
}

.btp-content-wrapper {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 40px;
    align-items: start;
}

.btp-content {
    min-width: 0;
}

/* Sections */
.btp-section {
    margin-bottom: 40px;
    padding-bottom: 40px;
    border-bottom: 1px solid var(--btp-border);
}

.btp-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
    padding-bottom: 0;
}

.btp-section-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--btp-secondary);
    margin: 0 0 24px 0;
}

/* Specific Points Grid */
.btp-points-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
}

.btp-point-item {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 16px;
    background: var(--btp-bg-light);
    border-radius: var(--btp-radius);
    transition: transform 0.2s, box-shadow 0.2s;
}

.btp-point-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--btp-shadow);
}

.btp-point-icon {
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--btp-primary);
    color: #FFFFFF;
    border-radius: 50%;
    flex-shrink: 0;
    font-size: 1.1rem;
}

.btp-point-content {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.btp-point-label {
    font-size: 0.85rem;
    color: var(--btp-text-light);
    font-weight: 500;
}

.btp-point-value {
    font-size: 0.95rem;
    color: var(--btp-text);
    line-height: 1.4;
}

/* Description */
.btp-description-content,
.btp-additional-content {
    font-size: 1rem;
    line-height: 1.7;
    color: var(--btp-text);
}

.btp-description-content p,
.btp-additional-content p {
    margin: 0 0 16px 0;
}

/* Gallery */
.btp-gallery-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.btp-gallery-item {
    aspect-ratio: 1;
    overflow: hidden;
    border-radius: var(--btp-radius);
    position: relative;
}

.btp-gallery-item.btp-gallery-featured {
    grid-column: span 2;
    grid-row: span 2;
}

.btp-gallery-item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.btp-gallery-item:hover img {
    transform: scale(1.05);
}

.btp-gallery-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: opacity 0.3s;
}

.btp-gallery-item:hover .btp-gallery-overlay {
    opacity: 1;
}

.btp-gallery-overlay i {
    color: #FFFFFF;
    font-size: 1.5rem;
}

/* Accordion */
.btp-accordion {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btp-accordion-item {
    border: 1px solid var(--btp-border);
    border-radius: var(--btp-radius);
    overflow: hidden;
}

.btp-accordion-header {
    width: 100%;
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 16px 20px;
    background: #FFFFFF;
    border: none;
    cursor: pointer;
    text-align: left;
    transition: background 0.2s;
}

.btp-accordion-header:hover {
    background: var(--btp-bg-light);
}

.btp-accordion-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    flex-shrink: 0;
}

/* Color variations */
.btp-accordion-item[data-color="green"] .btp-accordion-icon {
    background: #E8F5E9;
    color: #2E7D32;
}

.btp-accordion-item[data-color="red"] .btp-accordion-icon {
    background: #FFEBEE;
    color: #C62828;
}

.btp-accordion-item[data-color="blue"] .btp-accordion-icon {
    background: #E3F2FD;
    color: #1565C0;
}

.btp-accordion-item[data-color="purple"] .btp-accordion-icon {
    background: #F3E5F5;
    color: #7B1FA2;
}

.btp-accordion-item[data-color="orange"] .btp-accordion-icon {
    background: #FFF3E0;
    color: #EF6C00;
}

.btp-accordion-item[data-color="teal"] .btp-accordion-icon {
    background: #E0F2F1;
    color: #00796B;
}

.btp-accordion-title {
    flex: 1;
    font-size: 1rem;
    font-weight: 600;
    color: var(--btp-text);
}

.btp-accordion-arrow {
    color: var(--btp-text-light);
    transition: transform 0.3s;
}

.btp-accordion-item.active .btp-accordion-arrow {
    transform: rotate(180deg);
}

.btp-accordion-content {
    display: none;
    padding: 0 20px 20px 68px;
}

.btp-accordion-item.active .btp-accordion-content {
    display: block;
}

.btp-list {
    list-style: none;
    margin: 0;
    padding: 0;
}

.btp-list li {
    padding: 8px 0;
    padding-left: 24px;
    position: relative;
    color: var(--btp-text);
    border-bottom: 1px solid var(--btp-border);
}

.btp-list li:last-child {
    border-bottom: none;
}

.btp-list li::before {
    content: "•";
    position: absolute;
    left: 0;
    color: var(--btp-primary);
    font-weight: bold;
}

/* List Blocks Vertical Layout */
.btp-list-blocks-vertical {
    display: flex;
    flex-direction: column;
    gap: 32px;
}

.btp-list-block-item {
    padding-bottom: 24px;
    border-bottom: 1px solid var(--btp-border);
}

.btp-list-block-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.btp-list-block-title {
    display: flex;
    align-items: center;
    gap: 12px;
    font-size: 1.15rem;
    font-weight: 600;
    color: var(--btp-secondary);
    margin: 0 0 16px 0;
}

.btp-list-block-title i {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--btp-bg-light);
    color: var(--btp-primary);
    border-radius: 50%;
    font-size: 0.9rem;
}

.btp-list-block-content {
    color: var(--btp-text);
    font-size: 1rem;
    line-height: 1.6;
}

.btp-list-block-content p {
    margin: 0 0 1em 0;
}

.btp-list-block-content p:last-child {
    margin-bottom: 0;
}

.btp-list-block-content ul,
.btp-list-block-content ol {
    margin: 0 0 1em 0;
    padding-left: 1.5em;
}

.btp-list-block-content ul:last-child,
.btp-list-block-content ol:last-child {
    margin-bottom: 0;
}

.btp-list-block-content li {
    margin-bottom: 0.5em;
    color: var(--btp-text);
}

.btp-list-block-content li:last-child {
    margin-bottom: 0;
}

.btp-list-block-content a {
    color: var(--btp-primary);
    text-decoration: underline;
}

.btp-list-block-content a:hover {
    text-decoration: none;
}

/* Prices Table */
.btp-prices-table {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.btp-price-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 16px 20px;
    background: var(--btp-bg-light);
    border-radius: var(--btp-radius);
}

.btp-price-range {
    font-size: 0.95rem;
    color: var(--btp-text);
}

.btp-price-value {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--btp-primary);
}

.btp-price-per {
    font-size: 0.85rem;
    font-weight: 400;
    color: var(--btp-text-light);
    margin-left: 4px;
}

.btp-min-participants-note {
    margin-top: 16px;
    padding: 12px 16px;
    background: #FFF3E0;
    border-radius: var(--btp-radius);
    color: #EF6C00;
    font-size: 0.9rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

/* Sidebar Booking Card */
.btp-sidebar {
    position: sticky;
    top: 20px;
}

.btp-booking-card {
    background: #FFFFFF;
    border-radius: var(--btp-radius-lg);
    box-shadow: var(--btp-shadow-lg);
    overflow: hidden;
}

.btp-booking-header {
    padding: 24px;
    background: var(--btp-secondary);
    color: #FFFFFF;
    text-align: center;
}

.btp-booking-header h3 {
    margin: 0 0 12px 0;
    font-size: 1.25rem;
    font-weight: 600;
}

.btp-starting-price {
    display: flex;
    align-items: baseline;
    justify-content: center;
    gap: 6px;
}

.btp-price-from {
    font-size: 0.85rem;
    opacity: 0.8;
}

.btp-price-amount {
    font-size: 1.75rem;
    font-weight: 700;
}

/* Booking Form */
.btp-booking-form {
    padding: 24px;
}

.btp-form-group {
    margin-bottom: 20px;
}

.btp-form-group label {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 8px;
    font-size: 0.9rem;
    font-weight: 600;
    color: var(--btp-text);
}

.btp-form-group label i {
    color: var(--btp-primary);
}

.btp-form-control {
    width: 100%;
    padding: 12px 16px;
    border: 1px solid var(--btp-border);
    border-radius: var(--btp-radius);
    font-size: 1rem;
    transition: border-color 0.2s, box-shadow 0.2s;
}

.btp-form-control:focus {
    outline: none;
    border-color: var(--btp-primary);
    box-shadow: 0 0 0 3px rgba(255, 85, 51, 0.1);
}

.btp-form-row {
    display: flex;
    gap: 12px;
}

.btp-form-half {
    flex: 1;
}

.btp-form-divider {
    margin: 24px 0;
    text-align: center;
    position: relative;
}

.btp-form-divider::before {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background: var(--btp-border);
}

.btp-form-divider span {
    position: relative;
    background: #FFFFFF;
    padding: 0 12px;
    font-size: 0.85rem;
    color: var(--btp-text-light);
}

/* Price Calculator */
.btp-price-calculator {
    background: var(--btp-bg-light);
    padding: 16px;
    border-radius: var(--btp-radius);
    margin-bottom: 20px;
}

.btp-calc-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

.btp-calc-row.btp-calc-total {
    border-top: 2px solid var(--btp-border);
    margin-top: 8px;
    padding-top: 16px;
}

.btp-calc-label {
    font-size: 0.9rem;
    color: var(--btp-text-light);
}

.btp-calc-value {
    font-weight: 600;
    color: var(--btp-text);
}

.btp-calc-total .btp-calc-label,
.btp-calc-total .btp-calc-value {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--btp-primary);
}

/* Submit Button */
.btp-submit-btn {
    width: 100%;
    padding: 16px 24px;
    background: var(--btp-primary);
    color: #FFFFFF;
    border: none;
    border-radius: var(--btp-radius);
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s, transform 0.1s;
}

.btp-submit-btn:hover {
    background: var(--btp-primary-dark);
}

.btp-submit-btn:active {
    transform: scale(0.98);
}

.btp-submit-btn:disabled {
    background: #CCCCCC;
    cursor: not-allowed;
    transform: none;
}

.btp-form-note {
    margin-top: 16px;
    padding: 12px;
    background: var(--btp-bg-light);
    border-radius: var(--btp-radius);
    font-size: 0.8rem;
    color: var(--btp-text-light);
    display: flex;
    align-items: flex-start;
    gap: 8px;
    line-height: 1.4;
}

.btp-form-note i {
    color: var(--btp-success);
    margin-top: 2px;
}

/* Messages */
.btp-form-messages {
    padding: 24px;
}

.btp-message {
    padding: 16px;
    border-radius: var(--btp-radius);
    display: flex;
    align-items: flex-start;
    gap: 12px;
}

.btp-message i {
    font-size: 1.25rem;
    margin-top: 2px;
}

.btp-message-success {
    background: #E8F5E9;
    color: #2E7D32;
}

.btp-message-error {
    background: #FFEBEE;
    color: #C62828;
}

/* jQuery UI Datepicker Override */
.ui-datepicker {
    font-family: inherit;
    padding: 16px;
    border-radius: var(--btp-radius);
    box-shadow: var(--btp-shadow-lg);
    border: none;
}

.ui-datepicker-header {
    background: var(--btp-primary);
    border: none;
    border-radius: var(--btp-radius);
    padding: 8px;
}

.ui-datepicker-title {
    color: #FFFFFF;
}

.ui-datepicker-prev,
.ui-datepicker-next {
    cursor: pointer;
}

.ui-datepicker td a {
    text-align: center;
    border-radius: 4px;
}

.ui-datepicker td a:hover {
    background: var(--btp-bg-light);
}

.ui-datepicker td a.ui-state-active {
    background: var(--btp-primary);
    color: #FFFFFF;
}

/* Responsive */
@media (max-width: 992px) {
    .btp-content-wrapper {
        grid-template-columns: 1fr;
    }
    
    .btp-sidebar {
        position: relative;
        top: 0;
    }
    
    .btp-hero {
        height: 300px;
    }
    
    .btp-tour-title {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    .btp-points-grid {
        grid-template-columns: 1fr;
    }
    
    .btp-gallery-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .btp-gallery-item.btp-gallery-featured {
        grid-column: span 2;
        grid-row: span 1;
    }
    
    .btp-hero {
        height: 250px;
    }
    
    .btp-tour-title {
        font-size: 1.5rem;
    }
    
    .btp-form-row {
        flex-direction: column;
        gap: 0;
    }
}

@media (max-width: 480px) {
    .btp-container {
        padding: 0 16px;
    }
    
    .btp-booking-form {
        padding: 16px;
    }
    
    .btp-price-row {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}
