/* CSS Reset - Exclude user-agent default styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    margin-block-start:0; 
    margin-block-end:0; 
    margin-inline-start:0;
    margin-inline-end:0;
    padding-block-start:0; 
    padding-block-end:0; 
    padding-inline-start:0; 
    padding-inline-end:0;
}

/* Remove default list styles */
ul, ol {
    list-style: none;
}

/* Remove default link styles */
a {
    text-decoration: none;
    color: inherit;
}

/* Remove default button styles */
button {
    border: none;
    background: none;
    font-family: inherit;
    cursor: pointer;
}

/* Remove default input styles */
input, textarea, select {
    font-family: inherit;
    font-size: inherit;
    border: none;
    outline: none;
}

/* Farbkonzept */
:root {
    --primary-color: #d8a95d; /* Goldbraun */
    --text-color: #333; /* Standard Textfarbe */
}

/* Collapse Arrow Animation */
.collapse-arrow {
    transition: transform 0.3s ease;
    font-size: 1.2em;
    color: #666;
}

/* Collapse transitions */
.collapse {
    transition: height 0.35s ease;
    overflow: hidden;
}

.collapse:not(.show) {
    display: none;
}

.collapse.show {
    display: block;
}

/* Allgemeine Stile */
body {
    font-family: Arial, sans-serif;
    font-size: 13px; /* Standard Textgröße */
    background-color: var(--primary-color); /* Grundfarbe */
    background-image: url("../images/trav-acc-tools-back-VZTypzj.png");
    background-size: cover;
    background-position: center center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    color: var(--text-color);
    margin: 0;
    padding: 0;
    min-height: 100vh; /* Mindesthöhe für Sticky Footer */
    display: flex;
    flex-direction: column;
}

/* Standard Überschriften-Größen */
h1 {
    color: #2c3e50;
    font-size: 1.5rem;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid #71452b;
}

h2 {
    color: #2c3e50;
    font-size: 1.25rem;
    margin-top: 40px;
    margin-bottom: 15px;
    padding-bottom: 8px;
    border-bottom: 1px solid #ddd;
}

h3 {
    font-size: 16px;
    color: #935c32;
}

a {
    color: #1014ec;
    text-decoration: none;
    font-weight: bold;
}

a:hover {
    text-decoration: underline;
}

/* Content */
.content {
    margin: 20px auto; /* Zentrierung und Abstand nach oben/unten */
    padding: 0 20px; /* Innenabstand */
    background-color: #f8f4e6; /* Einheitlicher Hintergrund */
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1); /* Optional: Schatten */
    border-radius: 5px; /* Optional: Abgerundete Ecken */
    flex: 1; /* Content nimmt verfügbaren Platz ein */
    border: 1px solid #e6d5a8;
}

.import-timestamp {
    font-size: 0.75rem;
    font-weight: 300;
    color: #666;
    margin-left: 15px;
}

/* Page Header */
.page-header {
    background-color: #f8f4e6; /* Einheitlicher Hintergrund */
    padding: 20px 30px;
    border-radius: 0;
    box-shadow: none;
    margin-bottom: 20px;
    border: none;
}

.page-header .lead {
    color: #666;
    font-size: 16px;
    margin: 5px 0 0 0;
}

/* Spielwelt-Selektor */
.game-world-selector {
    padding: 0 15px;
}

.game-world-selector .inline-form {
    display: inline-block;
    margin: 0;
}

.game-world-selector select {
    background-color: #935c32;
    color: white;
    border: 1px solid #71452b;
    padding: 5px 10px;
    border-radius: 3px;
    cursor: pointer;
    font-size: 14px;
    height: 30px;
    line-height: 20px;
}

.game-world-selector select:hover {
    background-color: #71452b;
}

.game-world-selector a {
    color: #d8a95d;
    text-decoration: none;
    font-weight: bold;
}

.game-world-selector a:hover {
    color: white;
}

/* Dropdown Menu - Moved to header.css */
/* NOTE: .dropdown-menu is defined in header.css */

.dropdown-menu li {
    margin: 0;
}

.dropdown-menu a {
    padding: 6px 15px;
    color: #333;
    text-decoration: none;
    display: block;
    font-size: 12px;
}

/* Dropdown anzeigen bei Hover */
.dropdown:hover .dropdown-menu {
    display: block;
}

/* User Info */
.user-info {
    display: flex;
    align-items: center;
    gap: 15px;
}

/* Versionsinfo */
.version-info {
    font-size: 12px;
    color: #f2e2c4;
    text-align: right;
}

/* Avatar */
.user-avatar {
    display: flex;
    align-items: center;
}

.avatar-image {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: #999;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Welcome Page Styles */
.welcome-content {
    background-color: #f8f4e6; /* Heller, warmer Hintergrund passend zum Layout */
    padding: 30px;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    margin: 20px auto;
    max-width: 1000px;
    border: 1px solid #e6d5a8; /* Subtiler Rand in passender Farbe */
}

.welcome-text {
    font-size: 16px;
    line-height: 1.6;
    color: #333;
}

.welcome-text p {
    margin-bottom: 20px;
}

.welcome-text h3 {
    color: #935c32;
    font-size: 20px;
    margin: 30px 0 15px 0;
    font-weight: bold;
}

.tools-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.tools-list li {
    padding: 8px 0;
    border-bottom: 1px solid #f0f0f0;
    color: #555;
}

.tools-list li:last-child {
    border-bottom: none;
}

/* Footer Styles */
.footer {
    background-color: #935c32;
    color: white;
    padding: 20px 0;
    margin-top: auto; /* Footer wird nach unten gedrückt */
}

.footer-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    gap: 15px;
}

.footer-links {
    display: flex;
    gap: 30px;
    justify-content: center;
}

.footer-links a {
    color: white;
    text-decoration: none;
    transition: color 0.3s;
    font-size: 13px;
}

.footer-links a:hover {
    color: #d8a95d;
}

.footer-copyright {
    text-align: center;
}

.footer-copyright p {
    margin: 0;
    font-size: 13px;
    color: #f2e2c4;
}

.captcha-group .g-recaptcha {
    margin-bottom: 10px;
}

/* Form Footer - Moved to forms.css */
/* NOTE: .form-footer is defined in forms.css */

.form-footer p {
    margin: 5px 0;
    font-size: 14px;
    color: #666;
}

.form-footer a {
    color: #935c32; /* Farblich an die Seite angepasst */
    text-decoration: none;
    font-weight: bold;
    transition: color 0.3s;
}

.form-footer a:hover {
    color: #d8a95d;
    text-decoration: underline;
}

/* World List Styles */
.world-list {
    list-style: none;
    padding: 0;
    margin: 20px 0;
}

.world-list li {
    padding: 15px;
    margin-bottom: 10px;
    background-color: #f8f4e6;
    border-radius: 5px;
    border-left: 3px solid #935c32;
}

.available-worlds {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 20px;
    margin-top: 20px;
}

.world-card {
    background-color: #f8f4e6;
    border-radius: 8px;
    padding: 20px;
    border: 2px solid #d8a95d;
    transition: transform 0.2s, box-shadow 0.2s;
}

.world-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(147, 92, 50, 0.2);
}

.world-card h4 {
    color: #935c32;
    margin-top: 0;
    margin-bottom: 10px;
}

.world-card p {
    font-size: 14px;
    line-height: 1.6;
    color: #666;
    margin-bottom: 15px;
}

.world-card .btn {
    width: 100%;
}

/* Dropdown divider */
.dropdown-divider {
    height: 1px;
    background-color: #71452b;
    margin: 5px 0;
    list-style: none;
}

/* Active world in dropdown */
.dropdown-menu a.active {
    background-color: #2d6b2d;
    color: white;
    font-weight: bold;
}

/* Account name in main navigation */
.header-account-name {
    font-size: 12px;
    font-style: italic;
    margin-left: 5px;
}

/* Dashboard Styles */
.dashboard-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 20px;
}

.dashboard-section {
    background-color: #f8f4e6;
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
    border: 2px solid #d8a95d;
}

.dashboard-section h2 {
    color: #935c32;
    margin-top: 0;
    margin-bottom: 15px;
    font-size: 20px;
    border-bottom: 2px solid #d8a95d;
    padding-bottom: 10px;
}

/* Info Grid - Moved to global.css */
/* NOTE: .info-grid is defined in global.css */

.info-item {
    display: flex;
    align-items: center;
}

.info-item label {
    font-weight: bold;
    color: #935c32;
    margin-right: 10px;
    min-width: 80px;
}

.info-item span {
    color: #333;
}

/* ===================================
   LAYOUT SPECIFIC STYLES
   =================================== */

/* Flash Messages Container */
.flash-messages-container {
    max-width: 1200px;
    margin: 0 auto 20px auto;
    padding: 0 20px;
}

.flash-messages-container .alert:last-child {
    margin-bottom: 0;
}

/* ===================================
   FARM LISTS (Oasen)
   =================================== */

.farmlist-controls {
    background: #f8f4ec;
    border: 1px solid #d8cbb4;
    border-radius: 6px;
    padding: 15px;
    margin-bottom: 20px;
}

.farmlist-form {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: flex-end;
}

.farmlist-form .form-row {
    display: flex;
    align-items: center;
    gap: 6px;
}

.farmlist-form label {
    font-weight: bold;
    color: #935c32;
    white-space: nowrap;
}

.farmlist-form .form-control {
    padding: 6px 10px;
    border: 1px solid #c9b896;
    border-radius: 4px;
    background: #fff;
}

.farmlist-form .coord-input {
    width: 90px;
}

.farmlist-count {
    font-style: italic;
    color: #666;
    margin-bottom: 10px;
}

.farmlist-table th a {
    color: #935c32;
    text-decoration: none;
    cursor: pointer;
}

.farmlist-table th a:hover {
    text-decoration: underline;
}

.farmlist-table .coords {
    color: #888;
    font-size: 0.85em;
    white-space: nowrap;
}

.farmlist-table .number-cell {
    text-align: right;
}

/* Ressourcen-Icons in Tabellen-Headern (Travian-Icons) */
.resource-header img {
    vertical-align: middle;
    display: inline-block;
}

.data-table th.resource-header,
.farmlist-table th.resource-header,
table th.resource-header {
    text-align: center;
    white-space: nowrap;
}

.farmlist-table .resource-cell {
    font-weight: bold;
    color: #2d6a4f;
}

.farmlist-form label.checkbox-label,
.farmlist-form label[for="only_animals"] {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    font-weight: normal;
    cursor: pointer;
}

/* Oasen-Link auf die Karte */
.farmlist-table .oasis-link {
    color: #935c32;
    text-decoration: none;
    white-space: nowrap;
}

.farmlist-table .oasis-link:hover {
    text-decoration: underline;
}

/* Oase ist bereits in einer Farmliste (grüne Markierung) */
.farmlist-table .oasis-in-farmlist {
    color: #2d6a4f;
    font-weight: bold;
}

.farmlist-table .oasis-in-farmlist .coords {
    color: #2d6a4f;
}

/* ===================================
   INACTIVE SEARCH - EW-Verlauf (7 Tage)
   =================================== */
.history-head {
    font-size: 0.7rem;
    white-space: nowrap;
}

.history-cell {
    white-space: nowrap;
    font-size: 0.75rem;
    padding: 2px 4px !important;
}

.history-day {
    display: inline-block;
    min-width: 30px;
    padding: 1px 3px;
    border-radius: 3px;
    text-align: center;
    font-variant-numeric: tabular-nums;
}

.history-day.growth-up {
    background: #d8f0d8;
    color: #1e6b1e;
}

.history-day.growth-down {
    background: #f8d7da;
    color: #a11a24;
}

.history-day.growth-flat {
    background: #e9e9e9;
    color: #666;
}

/* Angeklickte Ergebniszeile (Markierung) */
.data-table tbody tr.row-selected td {
    background: #d9d9d9;
}

#inactive-results .data-table tbody tr {
    cursor: pointer;
}

/* Spähen-Checkbox: aktivierte Zeile hellrot (überschreibt die graue Markierung) */
.spy-head {
    font-size: 0.7rem;
    white-space: nowrap;
}

.data-table tbody tr.row-spy td {
    background: #f8d7da;
}

/* ===================================
   PLAYER SEARCH - Account- und Dorfzeilen
   =================================== */
.player-search-table .player-row td {
    background: #f7ecd2;
    font-weight: 600;
    border-top: 2px solid #935c32;
}

.player-search-table .village-row td {
    font-size: 0.9em;
}

.player-search-table .village-row td:nth-child(3) {
    padding-left: 18px;
}

.player-search-table .village-row.village-lost td {
    color: #8a6d3b;
    font-style: italic;
}

.player-search-table .village-row .status-badge {
    margin-left: 6px;
    padding: 1px 6px;
    font-size: 10px;
    font-weight: normal;
}

/* Wachstumsfarben (Bootstrap-Klassen sind im Projekt nicht eingebunden) */
.player-search-table .text-success {
    color: #1e6b1e;
}

.player-search-table .text-danger {
    color: #a11a24;
}

/* ===================================
   PAGINATION (Blättermenü)
   =================================== */
.pagination {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    margin-top: 12px;
    flex-wrap: wrap;
}

.pagination .page-link {
    display: inline-block;
    min-width: 32px;
    padding: 4px 8px;
    border: 1px solid #c9b896;
    border-radius: 4px;
    background: #fff;
    color: #71452b;
    text-align: center;
    text-decoration: none;
    font-size: 0.85rem;
    line-height: 1.4;
}

.pagination a.page-link:hover {
    background: #f3deb8;
    border-color: #935c32;
}

.pagination .page-link.active {
    font-weight: bold;
    background: #935c32;
    border-color: #71452b;
    color: #fff;
}

.pagination .page-link.disabled {
    color: #bbb;
    background: #f5f5f5;
    border-color: #ddd;
    cursor: default;
}

.pagination .page-ellipsis {
    padding: 4px 2px;
    color: #935c32;
}
