:root {
    --tab-text-color: #1976d2;
    --primary-color: #000000;
    --secondary-color: #dc004e;
    --background-color: #f5f5f5;
    --text-color: #333;
    --card-background: #ffffff;
    --slide-duration: 225ms;
}

body {
    margin: 0;
    width: auto;
    text-align: center;
    background-color: var(--background-color);
    color: var(--text-color);
}

#container {
    width: 96%;
    margin: 0 auto;
    text-align: left;
    padding: 10px 0;
}

.desktop-only h3 {
    text-align: center;
}

.img {
    padding-top: 5px;
    width: 100%;
    height: auto;
    display: block;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.TimeLeft {
    margin-top: 10px;
    text-align: center;
    color: var(--tab-text-color);
    font-weight: 500;
}

.TimeLeft a:active,
a:visited {
    text-decoration: none;
    color: var(--tab-text-color);
}

.TimeLeft a:hover {
    color: var(--secondary-color);
}

#chart,
#FbPage,
#marketNews,
.tradingview-chart {
    float: left;
    background: var(--card-background);
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    padding: 5px;
    margin: 5px 5px 5px 0;
}


#FbPage,
#marketNews,
.tradingview-chart {
    width: 100%;
    min-width: 440px;
    max-width: 630px;
    overflow: hidden;
}

/* Tab Styles */
.tab-container {
    display: none;
    background: var(--card-background);
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    position: relative;
}

.tab-buttons {
    display: none;
    background: var(--card-background);
    border-bottom: 1px solid rgba(0, 0, 0, 0.12);
    position: relative;
    z-index: 3;
}

.tab-button {
    padding: 16px 24px;
    color: var(--tab-text-color);
    border: none;
    background: transparent;
    cursor: pointer;
    width: 50%;
    font-size: 16px;
    font-weight: 500;
    position: relative;
}

.tab-button:after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: var(--tab-text-color);
    transform: scaleX(0);
}

.tab-button.active {
    color: var(--tab-text-color);
}

.tab-button.active:after {
    transform: scaleX(1);
}

.tab-content {
    display: block;
    padding: 20px;
    position: absolute;
    top: 57px; /* Height of tab buttons */
    left: 0;
    width: 100%;
    transition: transform 0.3s ease;
    visibility: hidden;
    box-sizing: border-box;
}

.tab-content.active {
    visibility: visible;
    transform: translateX(0);
    z-index: 2;
}

.tab-content.slide-left {
    transform: translateX(-100%);
}

.tab-content.slide-right {
    transform: translateX(100%);
}

.tab-content.dragging {
    transition: none;
}

/* Price Table */
table {
    width: 100%;
    margin: 5px auto;
    border-collapse: collapse;
    background: var(--card-background);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

td {
    padding: 12px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.12);
}

tr:last-child td {
    border-bottom: none;
}

strong {
    color: var(--primary-color);
}

/* Mobile Styles */
@media screen and (max-width: 768px) {
    #chart,
    #FbPage,
    #marketNews {
        float: none;
        width: 100%;
        min-width: auto;
        max-width: 100%;
        padding: 0;
    }

    .tab-container {
        display: block;
        touch-action: pan-y pinch-zoom;
        position: relative;
        min-height: 538px;
    }

    .tab-buttons {
        display: flex;
        width: 100%;
    }

    .tab-content {
        touch-action: pan-y pinch-zoom;
        top: 57px; /* Height of tab buttons */
    }

    .desktop-only,
    .tradingview-chart {
        display: none;
    }

    table {
        width: 100%;
        max-width: none;
    }

    .mobile-only .img {
        width: 100vw;
        margin-left: calc(-50vw + 50%);
        margin-right: calc(-50vw + 50%);
        border-radius: 0;
        box-shadow: none;
        padding: 0;
    }

    .mobile-only .tab-content {
        padding: 0;
    }

    .mobile-only h3 {
        text-align: center;
        padding: 16px 0;
        margin: 0;
        background: var(--card-background);
        border-bottom: 1px solid rgba(0, 0, 0, 0.12);
    }

    .mobile-only table {
        padding: 16px;
    }
}

/* Desktop Styles */
@media screen and (min-width: 769px) {
    .mobile-only {
        display: none;
    }
}

/* Widget Styles */
.tradingview-widget-container,
.fb-comments {
    background: var(--card-background);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.tradingview-widget-copyright {
    padding: 8px;
    background: rgba(0, 0, 0, 0.03);
    text-align: center;
}

.tradingview-widget-copyright a {
    color: var(--primary-color);
    text-decoration: none;
}