/* ==========================================
   Stoke Gigs - Unified Stylesheet
   Baseline from index.php + Form & FAQ Additions
   ========================================== */

* {
    box-sizing: border-box;
}

/* ----------------------------------------------
   Theme Variables & Defaults (Dark Theme)
   ---------------------------------------------- */

body {
    margin: 0;
    padding: 0;
    background: #111111 url('https://www.stokegigs.co.uk/images/bgnd2.jpg') no-repeat center center fixed;
    background-size: cover;
    color: #dddddd;
    font-family: Arial, Helvetica, sans-serif;
    font-size: 14px;
    transition: background 0.3s ease, color 0.3s ease;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

.site-header {
    background: rgba(20, 20, 20, 0.85);
    border-bottom: 5px solid #cc0000;
    padding: 18px 20px;
    width: 100%;
    box-sizing: border-box;
    transition: background 0.3s ease;
}

.header-inner {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 15px;
}

.header-text-content {
    flex: 1;
    min-width: 0;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 10px;
}

.section-header .header-actions .gig-link {
    margin-left: 0;
}

.home-link {
    margin: 0;
    color: #ffffff;
    font-size: 28px;
    font-weight: normal;
    text-decoration: none;
}

.home-link:hover {
    color: inherit;
    text-decoration: none;
}

.site-title {
    margin: 0;
    color: #ffffff;
    font-size: 28px;
    font-weight: normal;
}

.site-title span {
    color: #ffcc00;
}

.site-subtitle {
    margin: 5px 0 0;
    color: #aaaaaa;
    font-size: 13px;
}

.site-subtitle a {
    color: inherit;
    text-decoration: underline;
}

.site-subtitle a:hover {
    color: #ffcc00;
}

/* ----------------------------------------------
   Dropdown Navigation Styles
   ---------------------------------------------- */

.nav-dropdown {
    position: relative;
    display: inline-block;
}

.menu-btn {
    background: #222222;
    color: #ffcc00;
    border: 1px solid rgba(255, 255, 255, 0.2);
    padding: 8px 16px;
    font-size: 15px;
    font-weight: bold;
    border-radius: 4px;
    cursor: pointer;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 6px;
    transition: background 0.2s ease, border-color 0.2s ease;
}

.menu-btn:hover {
    background: #333333;
    border-color: rgba(255, 255, 255, 0.4);
    color: #ffffff;
}

.dropdown-content {
    display: none;
    position: absolute;
    right: 0;
    top: calc(100% + 8px);
    background: #1e1e1e;
    min-width: 180px;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.15);
    border-radius: 6px;
    z-index: 9999;
    overflow: hidden;
}

.dropdown-content.show {
    display: block;
}

.dropdown-item {
    color: #dddddd;
    padding: 12px 16px;
    text-decoration: none;
    display: block;
    width: 100%;
    text-align: left;
    background: transparent;
    border: none;
    font-size: 14px;
    cursor: pointer;
    box-sizing: border-box;
    transition: background 0.15s ease;
}

.dropdown-item:hover {
    background-color: #333333;
    color: #ffcc00;
}

hr.site-divider {
    border: none;
    height: 4px;
    background-color: #cc0000;
    margin: 0;
    width: 100%;
}

.site-footer {
    background: rgba(20, 20, 20, 0.85);
    padding: 20px;
    text-align: center;
    font-size: 13px;
    color: #aaaaaa;
    margin-top: auto;
    border-top: 1px solid #333333;
    transition: background 0.3s ease, color 0.3s ease;
}

.site-footer a {
    color: inherit;
    text-decoration: underline;
}

.site-footer a:hover {
    color: #ffcc00;
}

/* ----------------------------------------------
   Main Content & Search (index.php)
   ---------------------------------------------- */

.container {
    max-width: 1100px;
    margin: 20px auto;
    padding: 0 15px;
    width: 100%;
    box-sizing: border-box;
}

.content {
    background: rgba(20, 20, 20, 0.4);
    border: 1px solid rgba(255, 255, 255, 0.15);
    box-shadow: 0 4px 20px rgba(0,0,0,0.5);
}

.search-container {
    padding: 15px;
    background: rgba(30, 30, 30, 0.6);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    display: flex;
    gap: 10px;
    align-items: center;
    flex-wrap: wrap;
}

.search-input {
    flex: 1;
    min-width: 200px;
    padding: 10px 14px;
    font-size: 15px;
    background: rgba(15, 15, 15, 0.6);
    color: #ffffff;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    outline: none;
}

.search-input:focus {
    border-color: #ffcc00;
    box-shadow: 0 0 5px rgba(255, 204, 0, 0.4);
}

.reset-btn, .share-btn {
    padding: 10px 16px;
    background: rgba(50, 50, 50, 0.8);
    color: #ffcc00;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 4px;
    cursor: pointer;
    font-size: 14px;
    font-weight: bold;
    white-space: nowrap;
    transition: all 0.2s ease;
}

.reset-btn:hover, .share-btn:hover {
    background: rgba(70, 70, 70, 0.9);
}

.reset-btn.is-filtered {
    background: #ffcc00;
    color: #111111;
    border-color: #ffcc00;
}

.reset-btn.is-filtered:hover {
    background: #ffdd33;
}

.section-header {
    background: rgba(35, 35, 35, 0.75);
    color: #ffcc00;
    padding: 10px 15px;
    font-size: 22px;
    font-weight: bold;
    border-bottom: 4px solid #cc0000;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 10px;
}

.gig-count {
    font-size: 14px;
    font-weight: normal;
    color: #cccccc;
    margin-left: 8px;
}

.section-header .gig-link {
    font-size: 18px;
    font-weight: normal;
    margin-left: 0;
}

/* ----------------------------------------------
   Gig List Items
   ---------------------------------------------- */

.gig {
    display: grid;
    grid-template-columns: 140px 1fr 300px;
    gap: 15px;
    padding: 12px 15px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(20, 20, 20, 0.5);
    cursor: pointer;
}

.gig:nth-child(even) {
    background: rgba(45, 45, 45, 0.5);
}

.gig:hover {
    background: rgba(70, 50, 30, 0.6);
}

.gig:last-child {
    border-bottom: none;
}

.gig-date-col {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 4px;
}

.gig-date {
    white-space: nowrap;
    color: #ffcc00;
    font-weight: bold;
    font-size: 15px;
}

.gig-artist {
    color: #ffffff;
    font-size: 17px;
    font-weight: bold;
    margin-bottom: 3px;
}

.gig-venue {
    color: #dddddd;
    font-size: 14px;
}

.gig-details {
    text-align: right;
    color: #cccccc;
    line-height: 1.6;
}

.gig-details span {
    margin-left: 12px;
}

.gig-genre {
    color: #aaaaaa;
    font-size: 13px;
}

.gig-link {
    display: inline-block;
    margin-left: 12px;
    padding: 3px 9px;
    background: #cc0000;
    color: #ffffff;
    text-decoration: none;
    font-size: 12px;
    font-weight: bold;
    border-radius: 2px;
}

.gig-link:hover {
    background: #e60000;
}

.no-gigs {
    padding: 30px;
    text-align: center;
    color: #cccccc;
    background: rgba(20, 20, 20, 0.5);
}

.hidden {
    display: none !important;
}

/* ----------------------------------------------
   Form Container & Inputs (event_form.html)
   ---------------------------------------------- */

.form-container {
    max-width: 500px;
    margin: 20px auto 40px auto;
    padding: 0 15px;
    width: 100%;
    box-sizing: border-box;
}

.form-container h2 {
    margin-top: 0;
    text-align: center;
    font-size: 20px;
    margin-bottom: 20px;
    color: #ffffff;
}

label { 
    display: block; 
    margin-top: 15px; 
    font-weight: bold; 
    font-size: 14px;
    color: #dddddd;
}

input, textarea { 
    width: 100%; 
    padding: 12px; 
    margin-top: 6px; 
    box-sizing: border-box; 
    background: #1e1e1e;
    border: 1px solid #333333; 
    color: #ffffff;
    border-radius: 4px; 
    font-size: 16px; 
    transition: background 0.2s, border-color 0.2s;
}

input:focus, textarea:focus {
    outline: none;
    border-color: #4CAF50;
    background: #252525;
}

[data-theme="dark"] input[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(1);
}

.btn-container { 
    display: flex; 
    gap: 10px; 
    margin-top: 25px; 
}

button.action-btn, .link-btn { 
    flex: 1; 
    padding: 14px 15px; 
    border: none; 
    border-radius: 4px; 
    cursor: pointer; 
    font-size: 15px; 
    font-weight: bold;
    color: white; 
    text-align: center;
    text-decoration: none;
    box-sizing: border-box;
    transition: background 0.2s;
}

.submit-btn { background: #2e7d32; }
.submit-btn:hover { background: #388e3c; }
.clear-btn { background: #c62828; }
.clear-btn:hover { background: #d32f2f; }

.back-btn-container {
    margin-top: 15px;
}

.back-btn {
    background: #333333;
    border: 1px solid #555555;
    display: block;
    width: 100%;
}

.back-btn:hover {
    background: #444444;
}

.msg-box { 
    margin-top: 20px; 
    padding: 12px; 
    display: none; 
    text-align: center; 
    font-weight: bold; 
    border-radius: 4px;
    font-size: 14px;
}

#success-msg { 
    background: rgba(46, 125, 50, 0.2);
    border: 1px solid #2e7d32;
    color: #81c784; 
}

#error-msg {
    background: rgba(198, 40, 40, 0.2);
    border: 1px solid #c62828;
    color: #ef5350;
}

/* ----------------------------------------------
   FAQ Accordion Styles (faq.php)
   ---------------------------------------------- */

.faq-item {
    border-bottom: 1px solid rgba(255, 255, 255, 0.08);
    background: rgba(20, 20, 20, 0.5);
}

.faq-item:nth-child(even) {
    background: rgba(45, 45, 45, 0.5);
}

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

.faq-question {
    padding: 16px 20px;
    color: #ffffff;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background 0.2s ease;
}

.faq-question:hover {
    background: rgba(70, 50, 30, 0.6);
}

.faq-arrow {
    font-size: 14px;
    color: #ffcc00;
    transition: transform 0.3s ease;
}

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

.faq-answer-wrapper {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.35s ease-out;
    background: rgba(15, 15, 15, 0.6);
}

.faq-answer-inner {
    padding: 15px 20px 20px 20px;
    color: #dddddd;
    line-height: 1.6;
    font-size: 16px;
    border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.faq-answer-inner a {
    color: #ffcc00;
    text-decoration: underline;
}

.faq-answer-inner a:hover {
    color: #ffffff;
}

.no-faqs {
    padding: 30px;
    text-align: center;
    color: #cccccc;
    background: rgba(20, 20, 20, 0.5);
}

/* ----------------------------------------------
   Light Theme Overrides
   ---------------------------------------------- */

body.light-theme,
[data-theme="light"] body {
    background: #eeeeee;
    color: #333333;
}

body.light-theme .site-header,
[data-theme="light"] .site-header {
    background: #ffffff;
    border-bottom: 5px solid #e85d04;
}

/* Force site title to black in Light Mode */
body.light-theme .site-title,
[data-theme="light"] .site-title {
    color: #000000;
}

body.light-theme .site-subtitle a:hover,
[data-theme="light"] .site-footer a:hover {
    color: #1976d2;
}

/* Dropdown Menu Light Theme Styling */
body.light-theme .menu-btn,
[data-theme="light"] .menu-btn {
    background: #ffffff;
    color: #111111;
    border: 1px solid #cccccc;
}

body.light-theme .menu-btn:hover,
[data-theme="light"] .menu-btn:hover {
    background: #f0f0f0;
}

body.light-theme .dropdown-content,
[data-theme="light"] .dropdown-content {
    background: #ffffff;
    border: 1px solid #cccccc;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

body.light-theme .dropdown-item,
[data-theme="light"] .dropdown-item {
    color: #222222;
}

body.light-theme .dropdown-item:hover,
[data-theme="light"] .dropdown-item:hover {
    background: #fff4eb;
    color: #e85d04;
}

body.light-theme .content,
[data-theme="light"] .form-container {
    background: #ffffff;
}

[data-theme="light"] .content {
    background: #ffffff;
    border: 1px solid #d5d5d5;
    box-shadow: none;
}

body.light-theme .search-container,
[data-theme="light"] .search-container {
    background: #f1f1f1;
    border-bottom: 1px solid #d5d5d5;
}

body.light-theme .search-input,
[data-theme="light"] input, 
[data-theme="light"] textarea {
    background: #ffffff;
    color: #333333;
    border: 1px solid #cccccc;
}

body.light-theme .search-input:focus,
[data-theme="light"] input:focus, 
[data-theme="light"] textarea:focus {
    border-color: #2e7d32;
    background: #ffffff;
    box-shadow: 0 0 5px rgba(232, 93, 4, 0.3);
}

[data-theme="light"] label {
    color: #555555;
}

body.light-theme .reset-btn, 
body.light-theme .share-btn,
[data-theme="light"] .reset-btn, 
[data-theme="light"] .share-btn {
    background: #e2e2e2;
    color: #333333;
    border: 1px solid #cccccc;
}

body.light-theme .reset-btn:hover, 
body.light-theme .share-btn:hover {
    background: #d0d0d0;
}

body.light-theme .reset-btn.is-filtered {
    background: #e85d04;
    color: #ffffff;
    border-color: #e85d04;
}

body.light-theme .reset-btn.is-filtered:hover {
    background: #c94d00;
}

body.light-theme .section-header,
[data-theme="light"] .section-header {
    background: #444444;
    color: #ffffff;
    border-bottom: 4px solid #e85d04;
}

body.light-theme .gig-count {
    color: #cccccc;
}

body.light-theme .gig,
[data-theme="light"] .gig {
    background: #ffffff;
    border-bottom: 1px solid #dddddd;
}

body.light-theme .gig:nth-child(even),
[data-theme="light"] .gig:nth-child(even) {
    background: #f7f7f7;
}

body.light-theme .gig:hover,
[data-theme="light"] .gig:hover {
    background: #fff4eb;
}

body.light-theme .gig-date,
[data-theme="light"] .gig-date {
    color: #e85d04;
}

body.light-theme .gig-artist,
[data-theme="light"] h2 {
    color: #222222;
}

body.light-theme .gig-venue,
[data-theme="light"] .gig-venue {
    color: #555555;
}

body.light-theme .gig-details,
[data-theme="light"] .gig-details {
    color: #555555;
}

body.light-theme .gig-genre,
[data-theme="light"] .gig-genre {
    color: #777777;
}

body.light-theme .gig-link,
[data-theme="light"] .gig-link {
    background: #e85d04;
}

body.light-theme .gig-link:hover,
[data-theme="light"] .gig-link:hover {
    background: #c94d00;
}

body.light-theme .no-gigs,
[data-theme="light"] .no-gigs {
    color: #777777;
    background: #ffffff;
}

[data-theme="light"] .site-footer {
    background: #ffffff;
    border-top: 1px solid #e0e0e0;
    color: #555555;
}

body.light-theme .faq-item {
    background: #ffffff;
    border-bottom: 1px solid #dddddd;
}

body.light-theme .faq-item:nth-child(even) {
    background: #f7f7f7;
}

body.light-theme .faq-question {
    color: #222222;
}

body.light-theme .faq-question:hover {
    background: #fff4eb;
}

body.light-theme .faq-arrow {
    color: #e85d04;
}

body.light-theme .faq-answer-wrapper {
    background: #f9f9f9;
}

body.light-theme .faq-answer-inner {
    color: #555555;
    border-top: 1px solid #eeeeee;
}

body.light-theme .faq-answer-inner a {
    color: #e85d04;
}

body.light-theme .faq-answer-inner a:hover {
    color: #222222;
}

body.light-theme .no-faqs {
    color: #777777;
    background: #ffffff;
}

/* ----------------------------------------------
   Responsive Media Queries
   ---------------------------------------------- */

@media (max-width: 750px) {
    .site-title {
        font-size: 23px;
    }

    .container {
        margin: 10px auto;
        padding: 0 8px;
    }

    .gig {
        display: block;
        padding: 12px;
    }

    .gig-date {
        margin-bottom: 4px;
    }

    .gig-artist {
        font-size: 16px;
    }

    .gig-details {
        text-align: left;
        margin-top: 8px;
    }

    .gig-details span {
        margin-left: 0;
        margin-right: 12px;
    }

    .gig-link {
        margin-left: 0;
        margin-top: 6px;
    }
}

/* ----------------------------------------------
   Premium Listing Highlights
   ---------------------------------------------- */

.gig.gig-premium {
    border: 1px solid #f1c40f !important;
    background: rgba(241, 196, 15, 0.12) !important;
    box-shadow: inset 0 0 10px rgba(241, 196, 15, 0.15);
}

.gig.gig-premium:hover {
    background: rgba(241, 196, 15, 0.22) !important;
}

.premium-badge {
    background-color: #f1c40f;
    color: #111111;
    font-size: 11px;
    font-weight: bold;
    padding: 2px 6px;
    border-radius: 3px;
    white-space: nowrap;
    line-height: 1.2;
}

body.light-theme .gig.gig-premium,
[data-theme="light"] .gig.gig-premium {
    background: #fffdf0 !important;
    border-color: #d4ac0d !important;
}

body.light-theme .gig.gig-premium:hover,
[data-theme="light"] .gig.gig-premium:hover {
    background: #fff9d6 !important;
}