/**
 * PickTables Frontend Styles
 * Version: 1.0.0
 */

/* ===========================
   Global Styles
=========================== */
.picktables-search-form,
.picktables-registration-form,
.picktables-login-form,
.picktables-forgot-password-form {
    max-width: 100%;
    margin: 0 auto;
}

/* ===========================
   Forms
=========================== */
.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #333;
}

.form-group input[type="text"],
.form-group input[type="email"],
.form-group input[type="password"],
.form-group input[type="tel"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 15px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-size: 16px;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: #007bff;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
}

@media (max-width: 768px) {
    .form-row {
        grid-template-columns: 1fr;
    }
}

/* ===========================
   Buttons
=========================== */
.btn {
    display: inline-block;
    padding: 12px 24px;
    border: none;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 600;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
}

.btn-primary {
    background-color: #007bff;
    color: #fff;
}

.btn-primary:hover {
    background-color: #0056b3;
}

.btn-secondary {
    background-color: #6c757d;
    color: #fff;
}

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

.btn-success {
    background-color: #28a745;
    color: #fff;
}

.btn-danger {
    background-color: #dc3545;
    color: #fff;
}

/* ===========================
   Search Form
=========================== */
.picktables-search-form {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.search-fields {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    align-items: end;
}

@media (max-width: 768px) {
    .search-fields {
        grid-template-columns: 1fr;
    }
}

/* ===========================
   Venues List
=========================== */
#picktables-venues-list {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.venue-card {
    background: #fff;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    transition: transform 0.3s, box-shadow 0.3s;
}

.venue-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0,0,0,0.2);
}

.venue-card img {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.venue-card-content {
    padding: 20px;
}

.venue-card-title {
    font-size: 20px;
    font-weight: 700;
    margin-bottom: 10px;
    color: #333;
}

.venue-card-excerpt {
    font-size: 14px;
    color: #666;
    margin-bottom: 10px;
    line-height: 1.5;
}

.venue-card-location {
    font-size: 14px;
    color: #888;
    margin-bottom: 15px;
}

.venue-card-rating {
    display: flex;
    align-items: center;
    margin-bottom: 15px;
}

.venue-card-rating .stars {
    color: #ffc107;
    margin-right: 5px;
}

.venue-card-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* ===========================
   Venue Detail Page
=========================== */
.venue-detail-container {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 30px;
    margin-top: 30px;
}

@media (max-width: 992px) {
    .venue-detail-container {
        grid-template-columns: 1fr;
    }
}

.venue-detail-left {
    background: #fff;
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.venue-detail-right {
    position: sticky;
    top: 20px;
    height: fit-content;
}

.booking-widget {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.venue-banner {
    width: 100%;
    height: 400px;
    object-fit: cover;
    border-radius: 8px;
    margin-bottom: 20px;
}

.venue-title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 15px;
    color: #333;
}

.venue-meta {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.venue-meta-item {
    display: flex;
    align-items: center;
    gap: 5px;
    color: #666;
}

.venue-description {
    font-size: 16px;
    line-height: 1.8;
    color: #555;
    margin-bottom: 30px;
}

/* ===========================
   Menu Section
=========================== */
.menu-section {
    margin-top: 40px;
}

.menu-section h3 {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 20px;
    color: #333;
}

.pt-menu-items {
    display: grid;
    gap: 15px;
}

.pt-menu-item {
    display: flex;
    justify-content: space-between;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 6px;
}

.pt-menu-item-name {
    font-weight: 600;
    color: #333;
}

.pt-menu-item-description {
    font-size: 14px;
    color: #666;
    margin-top: 5px;
}

.pt-menu-item-price {
    font-weight: 700;
    color: #007bff;
}

/* ===========================
   Time Slots
=========================== */
.time-slots-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
    gap: 10px;
    margin-top: 20px;
}

.time-slot {
    padding: 12px;
    text-align: center;
    background: #f8f9fa;
    border: 2px solid #ddd;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.3s;
}

.time-slot:hover {
    background: #e9ecef;
    border-color: #007bff;
}

.time-slot.selected {
    background: #007bff;
    color: #fff;
    border-color: #007bff;
}

.time-slot.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ===========================
   Booking Form
=========================== */
.booking-form {
    margin-top: 20px;
}

.booking-summary {
    background: #f8f9fa;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.booking-summary-item {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
    padding-bottom: 10px;
    border-bottom: 1px solid #ddd;
}

.booking-summary-item:last-child {
    border-bottom: none;
}

/* ===========================
   My Bookings
=========================== */
.bookings-list {
    display: grid;
    gap: 20px;
    margin-top: 30px;
}

.booking-card {
    background: #fff;
    padding: 25px;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.booking-header {
    display: flex;
    justify-content: space-between;
    align-items: start;
    margin-bottom: 20px;
}

.booking-reference {
    font-size: 18px;
    font-weight: 700;
    color: #333;
}

.booking-status {
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
}

.booking-status.pending {
    background: #ffc107;
    color: #000;
}

.booking-status.confirmed {
    background: #28a745;
    color: #fff;
}

.booking-status.cancelled {
    background: #dc3545;
    color: #fff;
}

.booking-status.completed {
    background: #6c757d;
    color: #fff;
}

.booking-details {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 15px;
}

.booking-detail-item {
    display: flex;
    flex-direction: column;
}

.booking-detail-label {
    font-size: 12px;
    color: #888;
    margin-bottom: 5px;
    text-transform: uppercase;
}

.booking-detail-value {
    font-size: 16px;
    color: #333;
    font-weight: 600;
}

/* ===========================
   Messages & Alerts
=========================== */
.picktables-message,
#picktables-login-message,
#picktables-register-message,
#picktables-register-vo-message,
#picktables-forgot-password-message {
    margin-top: 20px;
    padding: 15px;
    border-radius: 6px;
}

.message-success {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    color: #155724;
}

.message-error {
    background: #f8d7da;
    border: 1px solid #f5c6cb;
    color: #721c24;
}

.message-info {
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    color: #0c5460;
}

/* ===========================
   Form Links
=========================== */
.form-links {
    margin-top: 20px;
    text-align: center;
}

.form-links a {
    color: #007bff;
    text-decoration: none;
}

.form-links a:hover {
    text-decoration: underline;
}

/* ===========================
   Loading States
=========================== */
.loading {
    text-align: center;
    padding: 40px;
}

.loading-spinner {
    border: 3px solid #f3f3f3;
    border-top: 3px solid #007bff;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 0 auto;
}

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

/* ===========================
   Responsive Utilities
=========================== */
@media (max-width: 768px) {
    .venue-detail-right {
        position: static;
    }
    
    .booking-widget {
        position: fixed;
        bottom: 0;
        left: 0;
        right: 0;
        border-radius: 20px 20px 0 0;
        z-index: 999;
    }
}

/* ===========================
   Accessibility
=========================== */
.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border-width: 0;
}

/* Focus styles for accessibility */
a:focus,
button:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid #007bff;
    outline-offset: 2px;
}