@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;700&display=swap');

body {
    background: #000;
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    margin: 0;
    font-size: 16px;
    line-height: 1.5;
    -webkit-text-size-adjust: 100%;
    touch-action: manipulation;
}

.container {
    padding: 20px 20px 70px 20px;
    max-width: 100%;
}

h1, h2, h3, h4, h5, h6 {
    font-family: 'Montserrat', sans-serif;
    font-weight: 700;
    text-transform: uppercase;
    margin-bottom: 20px;
    letter-spacing: 1px;
    color: #fff;
}

p, .card-text, .card-title, .form-label, .form-check-label, .alert {
    color: #fff !important;
}

.card {
    background: #111;
    border: 1px solid #333;
    box-shadow: 0 4px 12px rgba(255, 255, 255, 0.05);
    overflow: hidden;
}

.card-img-top {
    object-fit: contain;
    width: 100%;
    background: #000;
}

.post-feed .card-img-top {
    height: auto;
    max-width: 100%;
}

.card-header {
    background: #111;
    color: #fff !important;
    border-bottom: 1px solid #333;
}

.card-header a {
    color: #fff;
}

.card-header a:hover {
    color: #ccc;
}

.blur-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2;
}

.btn {
    background: #000;
    color: #fff;
    border: 1px solid #333;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    position: relative;
    z-index: 10;
}

/* Override Bootstrap's default button states for .like-post with higher specificity */
button.btn.like-post,
button.btn.like-post:hover,
button.btn.like-post:active,
button.btn.like-post:focus,
button.btn.like-post.liked {
    background: #000 !important;
    color: #fff !important;
    border: 1px solid #333 !important;
    box-shadow: none !important;
    opacity: 1 !important;
    outline: none !important;
    -webkit-tap-highlight-color: transparent !important; /* Disable Thunkable webview tap highlight */
}

button.btn.like-post .like-count {
    opacity: 1 !important;
}

.btn-group .btn {
    border: 1px solid #fff;
}

.btn-group .btn.active {
    background: #222;
}

.form-control, .form-control-file, textarea.form-control, select.form-control {
    background: #000;
    border: 1px solid #fff;
    color: #fff;
    padding: 12px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.form-control[type="date"]::-webkit-calendar-picker-indicator {
    filter: invert(1);
    cursor: pointer;
}

.form-control:focus, .form-control-file:focus, textarea.form-control:focus, select.form-control:focus {
    background: #000;
    border-color: #ccc;
    color: #fff;
    outline: none;
    box-shadow: 0 0 5px rgba(255, 255, 255, 0.2);
}

.form-control::placeholder {
    color: #999;
}

select.form-control {
    appearance: none;
    background: url('data:image/svg+xml;utf8,<svg fill="white" height="24" viewBox="0 0 24 24" width="24" xmlns="http://www.w3.org/2000/svg"><path d="M7 10l5 5 5-5z"/></svg>') no-repeat right 10px center;
    background-size: 20px;
}

.search-form {
    display: flex;
    align-items: stretch;
    margin-bottom: 20px;
}

.search-form .form-control {
    flex-grow: 1;
    border-right: none;
    height: 48px;
}

.search-form .btn {
    height: 48px;
    border: 1px solid #fff;
    border-left: none;
}

.post-feed {
    overflow-y: auto;
}

.post-feed::-webkit-scrollbar {
    width: 6px;
}

.post-feed::-webkit-scrollbar-thumb {
    background: #333;
}

.flexslider {
    border: 0;
    overflow: hidden;
    margin: 0 0 60px;
    background: #000 !important;
}

.flexslider .slides {
    position: relative;
}

.flexslider .slides li {
    background: #000 !important;
    display: flex !important;
    align-items: center;
    justify-content: center;
    min-height: 300px;
    width: 100%;
}

.flexslider .slides img,
.flexslider .slides video {
    width: 100%;
    max-height: 100%;
    object-fit: contain;
    background: #000;
}

.flex-direction-nav a {
    text-decoration: none;
    display: block;
    width: 40px;
    height: 45px;
    margin: -20px 0 0;
    position: absolute;
    top: 50%;
    z-index: 10;
    overflow: hidden;
    opacity: 0;
    cursor: pointer;
    color: rgba(0, 0, 0, 0.8);
    text-shadow: 1px 1px 0 rgba(255, 255, 255, 0.3);
    -webkit-transition: all 0.3s ease-in-out;
    -moz-transition: all 0.3s ease-in-out;
    transition: all 0.3s ease-in-out;
    background: none !important;
    font-size: 24px;
}

.flexslider:hover .flex-direction-nav .flex-prev {
    opacity: 0.7;
    left: 10px;
}

.flexslider:hover .flex-direction-nav .flex-next {
    opacity: 0.7;
    right: 10px;
}

.flex-direction-nav a:before {
    font-family: 'FontAwesome';
    content: '\f104';
}

.flex-direction-nav a.flex-next:before {
    content: '\f105';
}

.flex-direction-nav a:hover {
    opacity: 1;
}

.liked, .faved {
    color: #fff;
}

.tab-menu {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: #000;
    border-top: 1px solid #333;
    display: flex;
    justify-content: space-around;
    padding: 10px 0;
    z-index: 1000;
}

.tab-menu a {
    color: #fff;
    text-align: center;
    font-size: 24px;
    text-decoration: none;
    opacity: 0.7;
    transition: opacity 0.3s;
}

.tab-menu a.active {
    opacity: 1;
}

.tab-menu a:hover {
    opacity: 1;
}

.alert {
    background: #222;
    border: 1px solid #333;
    color: #fff;
}

.auth-links {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 12px;
    z-index: 1000;
}

.auth-links a {
    color: #fff;
    text-decoration: none;
    margin-left: 10px;
    text-transform: uppercase;
    font-weight: 600;
}

.auth-links a:hover {
    color: #ccc;
}

/* Admin Portal Styles */
.admin-container {
    display: flex;
    min-height: 100vh;
}

.admin-sidebar {
    width: 250px;
    background: #111;
    border-right: 1px solid #333;
    padding: 20px;
    position: fixed;
    top: 0;
    bottom: 0;
    z-index: 1000;
}

.admin-sidebar .logo {
    display: block;
    margin: 0 auto 30px;
    max-width: 150px;
}

.admin-sidebar h2 {
    font-size: 1.5rem;
    margin-bottom: 30px;
    text-align: center;
}

.admin-sidebar ul {
    list-style: none;
    padding: 0;
}

.admin-sidebar li {
    margin-bottom: 10px;
}

.admin-sidebar a {
    color: #fff;
    text-decoration: none;
    font-size: 14px;
    text-transform: uppercase;
    display: flex;
    align-items: center;
    padding: 10px;
    transition: background 0.3s;
}

.admin-sidebar a:hover, .admin-sidebar a.active {
    background: #222;
}

.admin-sidebar a i {
    margin-right: 10px;
}

.admin-content {
    margin-left: 250px;
    padding: 40px 40px 90px 40px;
    width: calc(100% - 250px);
    background: #000;
}

.dashboard {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.dashboard-card {
    background: #111;
    border: 1px solid #333;
    padding: 20px;
    text-align: center;
    transition: transform 0.3s, box-shadow 0.3s;
}

.dashboard-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 12px rgba(255, 255, 255, 0.1);
}

.dashboard-card h3 {
    font-size: 1.1rem;
    margin-bottom: 15px;
}

.dashboard-card .metric {
    font-size: 2.5rem;
    font-weight: 700;
    color: #fff;
}

.date-filter {
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.date-filter label {
    font-size: 14px;
    text-transform: uppercase;
}

.date-filter input {
    background: #000;
    border: 1px solid #fff;
    color: #fff;
    padding: 10px;
    font-size: 14px;
}

.date-filter .btn {
    padding: 10px 20px;
}

.chart-container {
    background: #111;
    border: 1px solid #333;
    padding: 20px;
    margin-bottom: 30px;
    max-width: 800px;
}

.table-responsive {
    margin-top: 20px;
}

.table {
    color: #fff;
    background: #1a1a1a;
    border: 1.5px solid #333;
}

.table th, .table td {
    border: 1.5px solid #333;
    padding: 12px;
    color: #fff !important;
    background-color: #1a1a1a;
}

.table th {
    background: #333;
    text-transform: uppercase;
    font-size: 14px;
}

.table tbody tr:hover {
    background: #222;
}

/* Business Logo Thumbnail */
.business-logo-thumbnail {
    width: 50px;
    height: 50px;
    object-fit: contain;
    background: #000;
}

/* Business Search Thumbnail */
.business-logo {
    width: 120px;
    height: 120px;
    object-fit: contain;
    margin-right: 15px;
}

/* Dropzone Styles */
.dropzone {
    border: 2px dashed #fff;
    background: #111;
    padding: 20px;
    text-align: center;
    cursor: pointer;
    transition: border-color 0.3s, background 0.3s;
    margin-bottom: 20px;
}

.dropzone.dragover, .dropzone.uploading {
    border-color: #ccc;
    background: #222;
}

.dropzone p {
    margin: 0;
    font-size: 14px;
    color: #999;
    text-transform: uppercase;
}

.upload-progress {
    margin-top: 10px;
    display: none;
    background: #333;
    height: 10px;
}

.progress-bar {
    background: #fff;
    height: 100%;
    transition: width 0.3s;
}

/* Sortable Media Grid */
.media-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.media-item {
    position: relative;
    border: 1px solid #333;
    background: #111;
    padding: 10px;
    cursor: move;
    transition: transform 0.3s;
}

.media-item img, .media-item video {
    width: 100%;
    object-fit: contain;
}

.media-item .delete-media {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    border: none;
    color: #fff;
    padding: 5px;
    cursor: pointer;
}

.media-item:hover {
    transform: scale(1.05);
}

/* Post Button and Modal */
.post-button {
    position: fixed;
    top: 20px;
    right: 20px;
    background: #222;
    color: #fff;
    border: 1px solid #fff;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    z-index: 1000;
    transition: background 0.3s;
}

.post-button:hover {
    background: #333;
}

.post-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
}

.post-modal-content {
    background: #111;
    padding: 20px;
    border: 1px solid #333;
    max-width: 500px;
    width: 90%;
    border-radius: 5px;
    position: relative;
}

.post-modal-content h2 {
    font-size: 1.5rem;
    margin-bottom: 20px;
}

.post-modal-content .btn-close {
    position: absolute;
    top: 10px;
    right: 10px;
    background: #fff;
    color: #000;
    padding: 5px;
    border-radius: 50%;
    opacity: 1;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

/* Post Image Upload Button */
.upload-image-btn {
    display: inline-block;
    background: #222;
    color: #fff;
    border: 1px solid #fff;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    transition: background 0.3s;
    margin-bottom: 10px;
}

.upload-image-btn:hover {
    background: #333;
}

/* Online Order Button */
.online-order-btn {
    display: inline-block;
    background: #222;
    color: #fff;
    border: 1px solid #fff;
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 600;
    text-transform: uppercase;
    text-decoration: none;
    transition: background 0.3s;
    margin-top: 10px;
    width: 100%;
}

.online-order-btn:hover {
    background: #333;
}

/* Social Media Icons */
.social-media-links {
    display: flex;
    gap: 15px;
    margin-top: 10px;
}

.social-media-links a {
    color: #fff;
    font-size: 24px;
    transition: color 0.3s;
}

.social-media-links a:hover {
    color: #ccc;
}

/* Toast Notification */
.toast {
    background: #222;
    border: 1px solid #333;
    color: #fff;
    font-family: 'Montserrat', sans-serif;
    text-transform: uppercase;
    font-size: 14px;
}

.toast-header {
    background: #333;
    color: #fff;
    border-bottom: 1px solid #333;
}

.toast-body {
    padding: 15px;
}

/* Modal Styling */
.modal-content {
    background: #111;
    border: 1px solid #333;
}

.modal-header, .modal-footer {
    border-color: #333;
}

.modal-title {
    color: #fff;
}

.btn-close-white {
    filter: invert(1);
}

@media (max-width: 992px) {
    .admin-sidebar {
        width: 200px;
    }
    .admin-content {
        margin-left: 200px;
        width: calc(100% - 200px);
    }
}

@media (max-width: 576px) {
    .card-img-top {
        /*height: 150px;*/
    }
    .post-feed .card-img-top {
        height: auto;
    }
    h1 {
        font-size: 1.5rem;
    }
    h2 {
        font-size: 1.25rem;
    }
    .auth-links {
        font-size: 10px;
    }
    .dashboard {
        grid-template-columns: 1fr;
    }
    .business-logo {
        width: 80px;
        height: 80px;
    }
    .business-logo-thumbnail {
        width: 30px;
        height: 30px;
    }
    .form-control, .form-control-file, textarea.form-control, select.form-control {
        font-size: 14px;
    }
    .social-media-links a {
        font-size: 32px;
    }
}