/* EZ Tickets - Mobile-First Responsive CSS */
:root {
    --primary-color: #FF6B35;
    --secondary-color: #004E89;
    --accent-color: #F77F00;
    --dark-bg: #1A1A2E;
    --light-bg: #F8F9FA;
    --text-dark: #2C3E50;
    --text-light: #ECF0F1;
    --success: #27AE60;
    --danger: #E74C3C;
    --warning: #F39C12;
    --border-radius: 12px;
    --box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: var(--text-dark);
    background: var(--light-bg);
    overflow-x: hidden;
}

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

/* Header & Navigation */
header {
    background: linear-gradient(135deg, var(--dark-bg) 0%, var(--secondary-color) 100%);
    color: var(--text-light);
    padding: 1rem 0;
    box-shadow: var(--box-shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 0.5rem 0;
    flex-wrap: wrap;
    gap: 1rem;
    position: relative;
}

.logo {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary-color);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: 5px;
    z-index: 1001;
}

/* Hamburger Menu Button */
.mobile-menu-toggle {
    display: none;
    flex-direction: column;
    justify-content: space-around;
    width: 30px;
    height: 25px;
    background: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
    z-index: 1001;
}

.mobile-menu-toggle span {
    width: 30px;
    height: 3px;
    background: var(--text-light);
    border-radius: 3px;
    transition: all 0.3s ease;
    transform-origin: center;
}

.mobile-menu-toggle.active span:nth-child(1) {
    transform: translateY(8px) rotate(45deg);
}

.mobile-menu-toggle.active span:nth-child(2) {
    opacity: 0;
}

.mobile-menu-toggle.active span:nth-child(3) {
    transform: translateY(-8px) rotate(-45deg);
}

.nav-links {
    display: flex;
    list-style: none;
    gap: 1rem;
    flex-wrap: wrap;
}

.nav-links a {
    color: var(--text-light);
    text-decoration: none;
    font-weight: 500;
    transition: var(--transition);
    padding: 0.5rem 1rem;
    border-radius: 6px;
    font-size: 0.95rem;
}

.nav-links a:hover {
    background: rgba(255, 255, 255, 0.1);
    color: var(--primary-color);
}

/* Hero Section */
.hero {
    background: linear-gradient(135deg, var(--secondary-color) 0%, var(--dark-bg) 100%);
    color: var(--text-light);
    padding: 3rem 0;
    text-align: center;
}

.hero h1 {
    font-size: 2rem;
    margin-bottom: 1rem;
    animation: fadeInUp 0.8s ease;
    padding: 0 15px;
}

.hero p {
    font-size: 1rem;
    margin-bottom: 1.5rem;
    animation: fadeInUp 0.8s ease 0.2s both;
    padding: 0 15px;
}

/* Events Grid */
.events-section {
    padding: 2rem 0;
}

.section-title {
    text-align: center;
    font-size: 1.8rem;
    margin-bottom: 2rem;
    color: var(--secondary-color);
    padding: 0 15px;
}

.events-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.event-card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: var(--transition);
    cursor: pointer;
}

.event-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.15);
}

.event-image {
    width: 100%;
    height: 200px;
    object-fit: cover;
}

.event-content {
    padding: 1.25rem;
}

.event-date {
    color: var(--primary-color);
    font-weight: bold;
    font-size: 0.85rem;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 5px;
}

.event-title {
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
    color: var(--dark-bg);
    line-height: 1.3;
}

.event-venue {
    color: #666;
    margin-bottom: 0.75rem;
    display: flex;
    align-items: center;
    gap: 5px;
    font-size: 0.9rem;
}

.event-artists {
    color: #888;
    font-size: 0.85rem;
    margin-bottom: 1rem;
}

.event-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 1rem;
    border-top: 1px solid #eee;
    flex-wrap: wrap;
    gap: 0.75rem;
}

.price-tag {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--accent-color);
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.75rem 1.25rem;
    border-radius: var(--border-radius);
    text-decoration: none;
    font-weight: 600;
    transition: var(--transition);
    border: none;
    cursor: pointer;
    font-size: 0.95rem;
    text-align: center;
}

.btn-primary {
    background: var(--primary-color);
    color: white;
}

.btn-primary:hover {
    background: #E55A2B;
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.4);
}

.btn-secondary {
    background: var(--secondary-color);
    color: white;
}

.btn-secondary:hover {
    background: #003D6E;
}

.btn-success {
    background: var(--success);
    color: white;
}

.btn-danger {
    background: var(--danger);
    color: white;
}

/* Forms */
.form-group {
    margin-bottom: 1.25rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
    color: var(--text-dark);
    font-size: 0.95rem;
}

.form-control {
    width: 100%;
    padding: 0.75rem;
    border: 2px solid #ddd;
    border-radius: 8px;
    font-size: 1rem;
    transition: var(--transition);
}

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

textarea.form-control {
    resize: vertical;
    min-height: 100px;
}

select.form-control {
    cursor: pointer;
}

/* Booking Form */
.booking-container {
    max-width: 800px;
    margin: 2rem auto;
    background: white;
    padding: 1.5rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.ticket-selection {
    margin: 1.5rem 0;
}

.ticket-item {
    background: var(--light-bg);
    padding: 1.25rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.ticket-info {
    flex: 1;
    min-width: 200px;
}

.ticket-info h4 {
    color: var(--secondary-color);
    margin-bottom: 0.3rem;
    font-size: 1.1rem;
}

.ticket-price {
    font-size: 1.1rem;
    font-weight: bold;
    color: var(--accent-color);
}

.quantity-control {
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.qty-btn {
    width: 35px;
    height: 35px;
    border: none;
    background: var(--primary-color);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
}

.qty-btn:hover {
    background: #E55A2B;
    transform: scale(1.05);
}

.qty-btn:active {
    transform: scale(0.95);
}

.qty-input {
    width: 60px;
    text-align: center;
    padding: 0.5rem;
    border: 2px solid #ddd;
    border-radius: 6px;
    font-size: 1rem;
}

/* Order Summary */
.order-summary {
    background: var(--light-bg);
    padding: 1.5rem;
    border-radius: var(--border-radius);
    margin-top: 1.5rem;
}

.summary-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 0.75rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #ddd;
    font-size: 0.95rem;
}

.summary-row.total {
    font-size: 1.2rem;
    font-weight: bold;
    color: var(--secondary-color);
    border-bottom: none;
    padding-top: 0.5rem;
}

/* Footer */
footer {
    background: var(--dark-bg);
    color: var(--text-light);
    padding: 2rem 0 1rem;
    margin-top: 3rem;
}

.footer-content {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.footer-section h3 {
    color: var(--primary-color);
    margin-bottom: 0.75rem;
    font-size: 1.1rem;
}

.footer-section p,
.footer-section ul {
    font-size: 0.9rem;
    line-height: 1.8;
}

.footer-section ul {
    list-style: none;
    padding: 0;
}

.footer-section ul li {
    margin-bottom: 0.5rem;
}

.footer-bottom {
    text-align: center;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    font-size: 0.9rem;
}

/* Alerts */
.alert {
    padding: 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: 0.95rem;
}

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

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

.alert-warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeeba;
}

/* Animations */
@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Loading Spinner */
.spinner {
    border: 4px solid #f3f3f3;
    border-top: 4px solid var(--primary-color);
    border-radius: 50%;
    width: 40px;
    height: 40px;
    animation: spin 1s linear infinite;
    margin: 2rem auto;
}

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

/* ========================================
   MOBILE RESPONSIVE DESIGN
   ======================================== */

/* Tablets and smaller (768px and below) */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    /* Header */
    .navbar {
        flex-direction: row;
        align-items: center;
        justify-content: space-between;
        gap: 0;
    }
    
    .logo {
        font-size: 1.3rem;
    }
    
    /* Show hamburger menu */
    .mobile-menu-toggle {
        display: flex;
    }
    
    /* Hide nav links by default on mobile */
    .nav-links {
        position: fixed;
        top: 70px;
        left: 0;
        right: 0;
        background: linear-gradient(135deg, var(--dark-bg) 0%, var(--secondary-color) 100%);
        flex-direction: column;
        width: 100%;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease-in-out;
        box-shadow: 0 5px 10px rgba(0,0,0,0.1);
        padding: 0;
        gap: 0;
    }
    
    .nav-links.active {
        max-height: 300px;
        padding: 1rem 0;
    }
    
    .nav-links li {
        width: 100%;
        text-align: center;
    }
    
    .nav-links a {
        display: block;
        width: 100%;
        padding: 1rem;
        font-size: 1rem;
        border-radius: 0;
        border-bottom: 1px solid rgba(255,255,255,0.1);
    }
    
    .nav-links li:last-child a {
        border-bottom: none;
    }
    
    /* Prevent body scroll when menu is open */
    body.menu-open {
        overflow: hidden;
    }
    
    /* Hero */
    .hero {
        padding: 2.5rem 0;
    }
    
    .hero h1 {
        font-size: 1.75rem;
        line-height: 1.3;
    }
    
    .hero p {
        font-size: 0.95rem;
    }
    
    /* Hero buttons */
    .hero .btn {
        padding: 0.65rem 1.25rem;
        font-size: 0.9rem;
        width: 100%;
        max-width: 250px;
    }
    
    /* Events */
    .section-title {
        font-size: 1.5rem;
    }
    
    .events-grid {
        grid-template-columns: 1fr;
        gap: 1.25rem;
    }
    
    .event-image {
        height: 180px;
    }
    
    .event-title {
        font-size: 1.2rem;
    }
    
    .event-footer {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .event-footer .btn {
        width: 100%;
    }
    
    /* Booking */
    .booking-container {
        padding: 1.25rem;
        margin: 1.5rem auto;
    }
    
    .ticket-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .quantity-control {
        width: 100%;
        justify-content: space-between;
    }
    
    .qty-input {
        width: 80px;
    }
    
    /* Order Summary */
    .order-summary {
        padding: 1.25rem;
    }
    
    .summary-row {
        font-size: 0.9rem;
    }
    
    .summary-row.total {
        font-size: 1.1rem;
    }
    
    /* Footer */
    .footer-content {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }
    
    .footer-section {
        text-align: center;
    }
    
    /* Forms */
    .form-control {
        font-size: 16px; /* Prevents zoom on iOS */
    }
    
    /* Buttons */
    .btn {
        width: 100%;
        padding: 0.85rem 1rem;
    }
}

/* Small Mobile (480px and below) */
@media (max-width: 480px) {
    .logo {
        font-size: 1.2rem;
    }
    
    .mobile-menu-toggle {
        width: 28px;
        height: 22px;
    }
    
    .mobile-menu-toggle span {
        width: 28px;
        height: 2.5px;
    }
    
    .nav-links.active {
        top: 65px;
    }
    
    .hero h1 {
        font-size: 1.5rem;
    }
    
    .hero p {
        font-size: 0.9rem;
    }
    
    .section-title {
        font-size: 1.3rem;
    }
    
    .event-card {
        margin-bottom: 0.5rem;
    }
    
    .event-content {
        padding: 1rem;
    }
    
    .event-title {
        font-size: 1.1rem;
    }
    
    .price-tag {
        font-size: 1.1rem;
    }
    
    .booking-container {
        padding: 1rem;
    }
    
    .ticket-info h4 {
        font-size: 1rem;
    }
    
    .qty-btn {
        width: 32px;
        height: 32px;
        font-size: 1.1rem;
    }
}

/* Touch-friendly enhancements */
@media (hover: none) and (pointer: coarse) {
    /* Increase tap targets for mobile */
    .btn {
        min-height: 44px;
    }
    
    .qty-btn {
        min-width: 44px;
        min-height: 44px;
    }
    
    .nav-links a {
        min-height: 44px;
        display: flex;
        align-items: center;
    }
    
    /* Remove hover effects on touch devices */
    .event-card:hover {
        transform: none;
    }
    
    .btn:hover {
        transform: none;
    }
}

/* Landscape orientation on mobile */
@media (max-width: 768px) and (orientation: landscape) {
    .hero {
        padding: 2rem 0;
    }
    
    .hero h1 {
        font-size: 1.5rem;
    }
}

/* Utility classes for mobile */
.mobile-only {
    display: none;
}

.desktop-only {
    display: block;
}

@media (max-width: 768px) {
    .mobile-only {
        display: block;
    }
    
    .desktop-only {
        display: none;
    }
}

/* Prevent text selection on buttons (mobile) */
.btn,
.qty-btn {
    -webkit-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

/* Smooth scrolling */
html {
    scroll-behavior: smooth;
}

/* Fix for iOS input zoom */
@media screen and (-webkit-min-device-pixel-ratio: 0) {
    select,
    textarea,
    input {
        font-size: 16px;
    }
}
