@import url('https://fonts.googleapis.com/css2?family=Cinzel:wght@700&family=Open+Sans&family=Pirata+One&display=swap');

body {
    font-family: 'Open Sans', Arial, sans-serif;
    margin: 0;
    padding: 0;
    background: linear-gradient(to bottom, #1b2c41 0%, #265075 100%);
    color: #fff;
    /* faster page transition */
    animation: fadeInBody 0.3s ease-in;
}

@keyframes fadeInBody {
    from { opacity: 0; }
    to { opacity: 1; }
}

/* Top navigation bar */
.top-nav {
    background: linear-gradient(#333, #222);
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
}


.top-nav a {
    color: #ffcc00;
    margin: 0 10px;
    text-decoration: none;
    font-family: 'Pirata One', cursive;
    font-size: 1.1em;
    transition: transform 0.3s;
}

.top-nav a:hover {
    color: #fff;
    text-shadow: 0 0 5px #ffcc00, 0 0 10px #fff;
    transform: translateY(-3px);
}

/* Banner area */
header {
        background: url('../img/anime-pirate.jpg') no-repeat center center;
    background-size: cover;
    height: 320px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-bottom: 4px solid #ffcc00;
    box-shadow: 0 0 15px #ffcc00;
    padding: 0;
}

header h1 {
    margin: 0;
    font-family: 'Pirata One', 'Cinzel', serif;
    color: #ffd86b;
    text-shadow: 0 0 10px #fff;
    animation: wave 4s infinite ease-in-out;
}

@keyframes wave {
    0% { transform: skewX(-5deg); }
    50% { transform: skewX(5deg); }
    100% { transform: skewX(-5deg); }
}

main {
    padding: 20px;
}

footer {
    background: linear-gradient(#332009, #734419);
    color: #ccc;
    text-align: center;
    padding: 10px;
    border-top: 4px solid #ffcc00;
    box-shadow: 0 0 15px #ffcc00;
}
.modal {
    display: none;
    position: fixed;
    z-index: 1;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.5);
}
.modal-content {
    background-color: rgba(0, 0, 0, 0.8);
    color: #fff;
    margin: 10% auto;
    padding: 20px;
    border: 1px solid #888;
    width: 80%;
    max-width: 600px;
    position: relative;
}
.close {
    color: #aaa;
    position: absolute;
    top: 10px;
    right: 15px;
    font-size: 28px;
    font-weight: bold;
    cursor: pointer;
}

/* Layout elements for main page */

.main-container {
    display: flex;
    gap: 20px;
    justify-content: center;
    align-items: flex-start;
}

.sidebar {
    background: rgba(0, 0, 0, 0.5);
    padding: 15px;
    border: 2px solid #ffcc00;
    border-radius: 8px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
}

.sidebar.left {
    width: 230px;
}

.sidebar.right {
    width: 260px;
}

.main-content {
    flex: 1;
    max-width: 640px;
}

.logo {
    text-align: center;
    font-family: 'Pirata One', cursive;
    font-size: 3em;
    color: #ffcc00;
    margin: 20px 0;
    text-shadow: 0 0 10px #fff;
}

.slider {
    height: 250px;
    background: linear-gradient(#005b96, #003f6d);
    border: 2px solid #ffcc00;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    margin-bottom: 20px;
}

.news-block {
    background: #f0e7d5;
    color: #333;
    border: 2px solid #ffcc00;
    border-radius: 8px;
    padding: 15px;
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.5);
    margin-bottom: 20px;
}

.news-block h2 {
    text-align: center;
    margin-top: 0;
    color: #2c2c2c;
}

.news-nav {
    text-align: center;
    margin-bottom: 10px;
}

.news-nav a {
    display: inline-block;
    padding: 4px 8px;
    margin: 0 4px;
    border-radius: 4px;
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    font-size: 0.9em;
}

.news-nav a.active { background: #666; }
.news-nav a.tab-important { background: #d9534f; }
.news-nav a.tab-updates { background: #5cb85c; }
.news-nav a.tab-events { background: #5bc0de; }
.news-nav a.tab-other { background: #9370db; }
.news-nav a.tab-admin { background: #444; }

.news-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.news-item {
    display: flex;
    align-items: center;
    border-bottom: 1px solid #ccc;
    padding: 6px 0;
}

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

.news-category {
    padding: 2px 6px;
    border-radius: 3px;
    color: #fff;
    margin-right: 10px;
    font-size: 0.9em;
    font-weight: bold;
}

.news-category.important { background: #d9534f; }
.news-category.updates { background: #5cb85c; }
.news-category.events { background: #5bc0de; }
.news-category.other { background: #9370db; }

.news-title {
    flex: 1;
    font-weight: bold;
}

.news-date {
    font-size: 0.85em;
    color: #555;
    margin-left: 10px;
}

.news-slider {
    position: relative;
    overflow: hidden;
}

.news-controls {
    text-align: center;
    margin-top: 10px;
}

.news-controls button {
    background: #ffcc00;
    color: #000;
    border: none;
    padding: 4px 8px;
    margin: 0 4px;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
}


.stats ul,
.character-stats ul {
    list-style: none;
    padding-left: 0;
}

.stats li,
.character-stats li {
    margin: 5px 0;
}

.login-box form input[type="text"],
.login-box form input[type="password"] {
    width: 80%;
    padding: 8px;
    margin: 0 auto 10px auto;
    border: 1px solid #ffcc00;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
    display: block;
}

.login-box input[type="submit"],
.login-box button {
    background: #ffcc00;
    color: #000;
    border: none;
    padding: 10px;
    width: 100%;
    border-radius: 5px;
    cursor: pointer;
    margin-bottom: 5px;
    font-weight: bold;
}

.login-box a {
    color: #ffcc00;
    text-decoration: none;
    font-size: 0.9em;
}

.subnav a {
    color: #ffcc00;
    margin-right: 10px;
    text-decoration: none;
}

.subnav a.active {
    font-weight: bold;
    text-shadow: 0 0 5px #ffcc00;
}

table.ranking {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
}

table.ranking th,
table.ranking td {
    border: 1px solid #444;
    padding: 4px 6px;
    text-align: left;
}

table.ranking th {
    background: #333;
}

/* small image displayed on each page */
.pirate-img {
    width: 80px;
    height: auto;
    display: block;
    margin: 10px auto 0 auto;
}

/* Generic form styling used across the site */
.styled-form {
    background: rgba(0, 0, 0, 0.6);
    border: 1px solid #ffcc00;
    border-radius: 8px;
    padding: 15px;
    max-width: 600px;
    margin: 20px auto;
}

.styled-form label {
    display: block;
    margin-bottom: 6px;
    color: #ffcc00;
    font-weight: bold;
}

.styled-form input[type="text"],
.styled-form input[type="password"],
.styled-form input[type="email"],
.styled-form textarea {
    width: 100%;
    padding: 8px;
    margin-bottom: 10px;
    border: 1px solid #ffcc00;
    border-radius: 5px;
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
}

.styled-form input[type="submit"] {
    background: #ffcc00;
    color: #000;
    border: none;
    padding: 10px;
    width: 100%;
    border-radius: 5px;
    cursor: pointer;
    font-weight: bold;
}

/* Статус сервера */
.server-status.online { color: #5cb85c; }
.server-status.offline { color: #d9534f; }

/* Полоса загрузки сервера */
.progress {
    width: 100%;
    height: 15px;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 5px;
    overflow: hidden;
    margin-top: 4px;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(to right, #5cb85c, #4cae4c);
    width: 0;
    transition: width 0.5s ease-in-out;
}