/* Body style */

body {
    background-color: #1a1a1a;
    font-family: 'Arial', sans-serif;
    /* Updated to a more common modern sans-serif font */
    color: #f0f0f0;
    /* Slightly lighter for better readability on dark background */
    -webkit-user-select: none;
    -khtml-user-select: none;
    -moz-user-select: none;
    -ms-user-select: none;
    user-select: none;
}

/* Standard tag styles */

button,
.button {
    padding: 4px 10px;
    border-radius: 3px;
    /* Increased from 1px for a more modern look */
    background-color: #333333;
    /* Darker, more subdued color */
    color: #ffffff;
    /* White text for contrast */
    font-size: 14px;
    font-weight: bold;
    border: none;
    cursor: pointer;
    margin: 0 4px;
    transition: background-color 0.3s;
    /* Smooth transition for hover */
}

button:hover,
.button:hover {
    background-color: #444444;
    /* Darker on hover for feedback */
}

input[type=password],
input[type=text] {
    font-size: 14px;
    background-color: rgba(50, 50, 50, 0.75);
    /* Darker and more transparent */
    border-radius: 3px;
    outline: none;
    border: none;
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.5);
    padding: 3px;
    color: #f0f0f0;
    transition: background-color 0.3s;
    /* Transition for hover */
}

input[type=password]:hover,
input[type=text]:hover {
    background-color: rgba(70, 70, 70, 0.825);
    /* Slightly darker on hover */
}

input[type=range] {
    -webkit-appearance: none;
    appearance: none;
    height: 8px;
    margin: 3px;
    background: rgba(200, 200, 200, 0.3);
    /* Lighter, semi-transparent */
    outline: none;
    transition: opacity .2s;
}

input[type=range]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    background: #f0f0f0;
    /* Light color for thumb */
    cursor: pointer;
    border-radius: 50%;
    /* Circular thumb for a modern look */
}

button:hover {
    opacity: 0.9;
    /* Subtle opacity change instead of .85 for a less drastic effect */
}

p {
    margin: 4px 0;
    padding: 0;
}

canvas {
    z-index: 0;
}

hr {
    border: 1px solid #444444;
    /* Darker color */
    width: 93%;
}

@media screen and (min-width: 1080px) {
    ::-webkit-scrollbar {
        width: 2px;
        height: 2px;
    }

    ::-webkit-scrollbar-track {
        background: transparent;
    }

    ::-webkit-scrollbar-thumb {
        background: rgba(200, 200, 200, 0.5);
        /* Lighter, semi-transparent */
        border-radius: 2px;
    }
}

/* Classes */

/* Text */

.header {
    font-size: 20px;
    text-shadow: 0 2px 3px rgba(0, 0, 0, 0.5);
    /* Increased blur for depth */
}

.info {
    font-size: 13px;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
    /* Slight increase in blur */
}

.link {
    text-decoration: none;
    cursor: pointer;
}

.link:hover {
    opacity: 0.9;
    text-shadow: 0 0 3px rgba(255, 255, 255, 0.3);
}

/* Text Coloring */

.colorSuccess {
    color: #4CAF50;
    /* Updated to a more vibrant green */
}

.colorWarning {
    color: #FFA000;
    /* Updated to a more vivid orange */
}

.colorError {
    color: #F44336;
    /* Updated to a bright red */
}

.colorParty {
    color: #2196F3;
    /* Updated to a more modern blue */
}

/* Buttons */

.link_button {
    font-weight: normal;
    background-color: transparent;
    color: #f0f0f0;
    padding: 0;
}

/* Content */

.box {
    border-radius: 3px;
    background-color: rgba(30, 30, 30, 0.75);
    /* Darker and more transparent */
    padding: 6px;
    line-height: 17px;
    box-shadow: 0 2px 3px rgba(0, 0, 0, 0.25);
    pointer-events: auto;
}

.inner-box {
    border-radius: 3px;
    background-color: rgba(40, 40, 40, 0.75);
    /* Darker inner box */
    box-shadow: 0 2px 3px rgba(0, 0, 0, 0.125);
    pointer-events: auto;
}

.content {
    border-radius: 3px;
    background-color: rgba(50, 50, 50, 0.5);
    /* Darker background */
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.25);
    padding: 2px;
}

.slot {
    position: relative;
    border-radius: 4px;
    background-color: rgba(255, 255, 255, 0.05);
    /* Very subtle lighter background */
    box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.05), inset 0 0 10px rgba(0, 0, 0, 0.5);
    /* Double border effect + Inner depth */
    border: 1px solid rgba(0, 0, 0, 0.3);
    /* Dark outer border */
    padding: 4px;
    width: 32px;
    height: 32px;
    margin: 2px 3px;
    display: inline-block;
    overflow: hidden;
}

.slot:hover {
    opacity: 0.9;
    cursor: pointer;
}

.bar {
    width: 100%;
    height: 11px;
    border-radius: 6px;
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.25);
    border: 1px solid #333333;
    overflow: hidden;
    margin-top: 8px;
}

.smaller_bar {
    width: 100%;
    height: 6px;
    border-radius: 6px;
    box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.25);
    border: 1px solid #333333;
    overflow: hidden;
    margin-top: 2px;
}

.bar_content {
    height: 100%;
    box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.25);
}

.cooldown {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    text-align: center;
    z-index: 0;
}

.portrait {
    width: 64px;
    height: 64px;
    background-color: rgba(0, 0, 0, 0.125);
    border-radius: 3px;
    border: 1px solid rgba(255, 255, 255, 0.325);
}

.thumb {
    width: 26px;
    height: 26px;
}

/* Overlay style - customization is not advised */

#overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 1;
    pointer-events: none;
}

/* guild UI Redesign */

#guilds_box,
#leaderboards_box,
#friends_box,
#journal_box,
#profile_box,
#settings_box,
#shop_box,
#displayBox,
#contextBox,
#bank_box {
    background-color: rgba(20, 20, 25, 0.95);
    border: 1px solid #333;
    border-radius: 8px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.5);
    color: #e0e0e0;
    font-family: 'Segoe UI', 'Roboto', 'Helvetica Neue', sans-serif;
    padding: 0 !important;
    /* Override default box padding to handle header/content structure */
    display: flex;
    flex-direction: column;
    pointer-events: auto;
}

.guild-header {
    background: linear-gradient(to bottom, #2a2a30, #202025);
    padding: 15px 20px;
    border-bottom: 1px solid #333;
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 8px 8px 0 0;
}

.guild-header h2 {
    margin: 0;
    font-size: 18px;
    color: #fff;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.guild-close-btn {
    background: transparent;
    border: none;
    color: #888;
    font-size: 20px;
    cursor: pointer;
    transition: color 0.2s;
    padding: 0;
    margin: 0;
}

.guild-close-btn:hover {
    color: #ef4444;
}

.guild-tabs {
    display: flex;
    background-color: #151518;
    padding: 0 20px;
    border-bottom: 1px solid #333;
}

.guild-tab-btn {
    background: transparent;
    border: none;
    color: #888;
    padding: 12px 15px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    border-bottom: 2px solid transparent;
    transition: all 0.2s;
    margin: 0;
    border-radius: 0;
}

.guild-tab-btn:hover {
    color: #ccc;
    background-color: rgba(255, 255, 255, 0.02);
}

.guild-tab-btn.active {
    color: #3b82f6;
    border-bottom-color: #3b82f6;
}

.guild-content {
    padding: 20px;
    flex: 1;
    overflow-y: auto;
    min-height: 350px;
}

/* guild UI Components */

.guild-btn {
    padding: 8px 16px;
    border-radius: 4px;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    border: none;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
}

.guild-btn-primary {
    background-color: #3b82f6;
    color: white;
}

.guild-btn-primary:hover {
    background-color: #2563eb;
    box-shadow: 0 2px 4px rgba(59, 130, 246, 0.3);
}

.guild-btn-secondary {
    background-color: #333;
    color: #e0e0e0;
}

.guild-btn-secondary:hover {
    background-color: #444;
}

.guild-btn-danger {
    background-color: rgba(239, 68, 68, 0.1);
    color: #ef4444;
    border: 1px solid rgba(239, 68, 68, 0.3);
}

.guild-btn-danger:hover {
    background-color: rgba(239, 68, 68, 0.2);
}

.guild-btn-sm {
    padding: 4px 8px;
    font-size: 11px;
}

.guild-input {
    background-color: #121212;
    border: 1px solid #333;
    color: #fff;
    padding: 8px 12px;
    border-radius: 4px;
    font-size: 13px;
    width: 100%;
    box-sizing: border-box;
    transition: border-color 0.2s;
}

.guild-input:focus {
    border-color: #3b82f6;
    outline: none;
}

.guild-label {
    display: block;
    font-size: 12px;
    color: #888;
    margin-bottom: 6px;
    font-weight: 500;
}

.guild-card {
    background-color: rgba(255, 255, 255, 0.07);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 10px;
}

/* Members Table */
.guild-table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px;
}

.guild-table th {
    text-align: left;
    color: #bbb;
    font-weight: 600;
    padding: 8px 10px;
    border-bottom: 1px solid #444;
}

.guild-table td {
    padding: 8px 10px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
    color: #eee;
}

.guild-table tr:hover td {
    background-color: rgba(255, 255, 255, 0.02);
}

.guild-stat-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    margin: 20px 0;
}

.guild-stat-box {
    background-color: rgba(0, 0, 0, 0.2);
    padding: 15px;
    border-radius: 6px;
    text-align: center;
}

.guild-stat-value {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    margin-bottom: 5px;
}

.guild-stat-label {
    font-size: 11px;
    color: #888;
    text-transform: uppercase;
}

@keyframes blink-red {
    0% {
        box-shadow: 0 0 5px red;
        border-color: red;
    }

    50% {
        box-shadow: 0 0 20px red;
        border-color: darkred;
    }

    100% {
        box-shadow: 0 0 5px red;
        border-color: red;
    }
}

.warning-popup {
    animation: blink-red 1s infinite;
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 15px;
    border: 2px solid red;
    border-radius: 8px;
    text-align: center;
    font-weight: bold;
    font-size: 16px;
    z-index: 20000;
}
