/* Star Citizen Community Hub - Stylesheet */

:root {
    --primary-color: #11abe9;
    --secondary-color: #38d9ff;
    --accent-color: #00f6ff;
    --dark-bg: #030509;
    --card-bg: #0d1117;
    --card-hover: #161b22;
    --border-color: #1f6feb;
    --border-subtle: #21262d;
    --text-primary: #ffffff;
    --text-secondary: #8b949e;
    --text-muted: #6e7681;
    --success-color: #3fb950;
    --error-color: #f85149;
    --warning-color: #d29922;
    --highlight-blue: rgba(17, 171, 233, 0.15);
    --highlight-cyan: rgba(56, 217, 255, 0.1);
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', 'Noto Sans', Helvetica, Arial, sans-serif;
    background: linear-gradient(135deg, rgba(3,5,9,0.85) 0%, rgba(10,15,26,0.7) 0%, rgba(3,5,9,0.85) 50%),
        url('../images/background4.jpg') no-repeat center center fixed;
    background-size: cover;
    background-attachment: fixed;
    background-repeat: no-repeat;
    background-position: center center;
    color: var(--text-primary);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Animated Background Effect */
body::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background:
        radial-gradient(circle at 20% 50%, rgba(17, 171, 233, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 80% 80%, rgba(56, 217, 255, 0.05) 0%, transparent 50%),
        radial-gradient(circle at 40% 20%, rgba(0, 246, 255, 0.03) 0%, transparent 50%);
    pointer-events: none;
    z-index: 0;
}

/* Container */
.container {
    max-width: 1400px;
    width: 100%;
    margin: 0 auto;
    padding: 0 20px;
    position: relative;
    z-index: 1;
}

/* Homepage Sections */
.homepage-sections {
    margin-top: 4rem;
}

.section-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
}

.section-card {
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
    text-align: center;
    transition: all 0.3s ease;
}

.section-card:hover {
    background: var(--card-hover);
    border-color: var(--border-color);
    transform: translateY(-5px);
    box-shadow: 0 10px 30px rgba(17, 171, 233, 0.2);
}

.section-card h3 {
    color: var(--primary-color);
    margin-bottom: 1rem;
    font-size: 1.5rem;
}

.section-card p {
    color: var(--text-secondary);
    margin-bottom: 1.5rem;
    line-height: 1.6;
}

/* Navigation */
.navbar {
    background: rgb(34 34 34 /  0.40);
    color: #fff;
    padding: 0.5em 0;
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg,
        transparent 0%,
        var(--primary-color) 20%,
        var(--secondary-color) 50%,
        var(--primary-color) 80%,
        transparent 100%);
    opacity: 0.3;
}

.navbar .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.nav-brand a {
    color: #fff;
    text-decoration: none;
    font-weight: bold;
    font-size: 1.2em;
}

.nav-menu {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    align-items: center;
}

.nav-menu > li {
    margin-left: 1em;
    position: relative;
}

.dropdown .dropbtn {
    background: none;
    border: none;
    color: #fff;
    font-size: 1em;
    cursor: pointer;
    text-decoration: none;
    padding: 0.5em 1em;
}

.dropdown-content {
    display: none;
    position: absolute;
    background: #333;
    min-width: 180px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    z-index: 1;
    top: 100%;
    left: 0;
}

.dropdown-content a {
    color: #fff;
    padding: 0.7em 1em;
    text-decoration: none;
    display: block;
    border-bottom: 1px solid #444;
}

.dropdown-content a:last-child {
    border-bottom: none;
}

.dropdown:hover .dropdown-content,
.dropdown:focus-within .dropdown-content {
    display: block;
}

.dropdown.open .dropdown-content {
    display: block;
}

.user-info {
    color: #fff;
    font-size: 0.95em;
    margin-left: 1em;
}

/* Main Content */
.main-content {
    min-height: calc(100vh - 200px);
    padding: 0rem 0;
    flex: 1 0 auto;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    color: var(--text-primary);
    margin-bottom: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
}

h1 {
    font-size: 2.5rem;
    color: var(--primary-color);
    text-shadow: 0 0 20px rgba(17, 171, 233, 0.3);
    border-bottom: 2px solid var(--border-color);
    padding-bottom: 1rem;
    margin-bottom: 2rem;
}

h2 {
    font-size: 2rem;
    color: var(--secondary-color);
}

/* Flash Messages */
.flash-message {
    margin: 1em 0;
    padding: 1em;
    border-radius: 4px;
}

.flash-success {
    background: #d4edda;
    color: #155724;
}

.flash-error {
    background: #f8d7da;
    color: #721c24;
}

.flash-warning {
    background: #fff3cd;
    color: #856404;
}

/* Cards */
.card {
    display: block;
    background: var(--card-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    height: 80vh;
    min-height: 600px;
    max-height: 90vh;
    display: flex;
    flex-direction: row;
}

.card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background: linear-gradient(90deg, var(--primary-color), var(--secondary-color));
    opacity: 0;
    transition: opacity 0.3s ease;
}

.card:hover {
    background: var(--card-hover);
    border-color: var(--border-color);
    transform: translateY(-2px);
    box-shadow: 0 8px 24px rgba(17, 171, 233, 0.15);
}

.card:hover::before {
    opacity: 1;
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid var(--border-subtle);
}

.card-title {
    font-size: 1.3rem;
    font-weight: 600;
    color: var(--primary-color);
    margin: 0;
}

.card-body {
    color: var(--text-secondary);
}

/* Nachrichtenbereich nur scrollen lassen */
.messages-main.tabs-content {
    height: 100%;
    max-height: 100%;
    overflow-y: auto;
    min-height: 0;
}

@media (max-width: 900px) {
    .card {
        flex-direction: column;
        height: auto;
        min-height: 0;
        max-height: none;
    }
    .messages-main.tabs-content {
        max-height: 60vh;
    }
}

/* Grid Layouts */
.grid {
    display: grid;
    gap: 1.5rem;
    margin-top: 2rem;
}

.grid-2 {
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
}

.grid-3 {
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
}

/* Forms */
.form-standard {
    max-width: 900px;
    width: 100%;
    margin: 0 auto;
    background: var(--card-bg);
    padding: 2rem;
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-weight: 500;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.5px;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.75rem 1rem;
    background: var(--dark-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-group input:focus,
.form-group textarea:focus,
.form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--highlight-blue);
    background: var(--card-bg);
}

.form-group textarea {
    resize: vertical;
    min-height: 120px;
}

.form-actions {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

/* Filter Form */
.filter-form {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
    margin-bottom: 2rem;
}

.filter-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    align-items: end;
}

.filter-group {
    display: flex;
    flex-direction: column;
}

.filter-group label {
    margin-bottom: 0.5rem;
    color: var(--text-primary);
    font-weight: 500;
    font-size: 0.85rem;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.filter-group input,
.filter-group select {
    padding: 0.75rem 1rem;
    background: var(--dark-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 6px;
    color: var(--text-primary);
    font-size: 1rem;
    transition: all 0.3s ease;
}

.filter-group input:focus,
.filter-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px var(--highlight-blue);
    background: var(--card-bg);
}

.filter-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

/* Trading Page Styles */
.trading-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1em;
    margin-bottom: 1.5em;
    flex-wrap: wrap;
}
.trades-list {
    margin-top: 2em;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(340px, 1fr));
    gap: 2em;
}
.trade-card {
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: 0 4px 16px #11abe930;
    padding: 1.5em 1.2em;
    display: flex;
    flex-direction: column;
    gap: 0.7em;
    position: relative;
    transition: box-shadow 0.2s, transform 0.2s;
}
.trade-card:hover {
    box-shadow: 0 8px 32px #11abe980;
    transform: scale(1.02);
}
.trade-avatar {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: #232a36;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 2px 8px #11abe930;
    border: 2px solid #11abe9;
}
.trade-title {
    margin: 0 0 0.2em 0;
    font-size: 1.2em;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.trade-meta {
    display: flex;
    gap: 0.7em;
    align-items: center;
    font-size: 0.97em;
    flex-wrap: wrap;
}
.trade-info {
    color: #fff;
    font-size: 1.05em;
}
.trade-description {
    color: #bfc9d8;
    font-size: 0.98em;
    overflow: hidden;
    text-overflow: ellipsis;
}
.trade-badge {
    font-size: 0.95em;
    padding: 0.3em 0.9em;
    border-radius: 12px;
    font-weight: 600;
}
.badge-buy {
    background: #3fb95020;
    color: #3fb950;
    border: 1px solid #3fb950;
}
.badge-sell {
    background: #e11a1a20;
    color: #e11a1a;
    border: 1px solid #e11a1a;
}
.badge-swap {
    background: #a259ff20;
    color: #a259ff;
    border: 1px solid #a259ff;
}
.badge-active{
    background: rgb(95 220 95 / 0, 22);
    color: #4dcb4d;
    border: 1px solid #7adc5f;
}
.btn-link {
    color: var(--primary-color);
    background: none;
    border: none;
    padding: 0;
    font-size: 1em;
    text-decoration: underline;
    cursor: pointer;
}

/* Buttons */
.btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 6px;
    font-size: 1rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    cursor: pointer;
    transition: all 0.3s ease;
    text-decoration: none;
    display: inline-block;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:hover::before {
    width: 300px;
    height: 300px;
}

.btn span {
    position: relative;
    z-index: 1;
}

.btn-primary {
    background: linear-gradient(135deg, var(--primary-color), var(--secondary-color));
    color: var(--text-primary);
    border: 1px solid var(--primary-color);
    box-shadow: 0 4px 15px rgba(17, 171, 233, 0.3);
}

.btn-primary:hover {
    box-shadow: 0 6px 25px rgba(17, 171, 233, 0.5);
    transform: translateY(-2px);
}

.btn-secondary {
    background: var(--card-bg);
    color: var(--text-secondary);
    border: 1px solid var(--border-color);
}

.btn-secondary:hover {
    background: var(--card-hover);
    color: var(--text-primary);
    border-color: var(--primary-color);
}

.btn-danger {
    background: linear-gradient(135deg, var(--error-color), #c9302c);
    color: var(--text-primary);
    border: 1px solid var(--error-color);
}

.btn-danger:hover {
    box-shadow: 0 6px 25px rgba(248, 81, 73, 0.4);
    transform: translateY(-2px);
}

.btn-success {
    background: linear-gradient(135deg, var(--success-color), #2ea043);
    color: var(--text-primary);
    border: 1px solid var(--success-color);
}

.btn-success:hover {
    box-shadow: 0 6px 25px rgba(63, 185, 80, 0.4);
    transform: translateY(-2px);
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
}

/* Tables */
.table-container {
    overflow-x: auto;
    background: var(--card-bg);
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
}

table {
    width: 100%;
    border-collapse: collapse;
}

thead {
    background: var(--dark-bg);
}

th {
    padding: 1rem;
    text-align: left;
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 1px;
    border-bottom: 2px solid var(--border-color);
}

td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-subtle);
    color: var(--text-secondary);
}

tr:hover {
    background: var(--highlight-blue);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.35rem 0.75rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.badge-success {
    background: rgba(63, 185, 80, 0.2);
    color: var(--success-color);
    border: 1px solid var(--success-color);
}

.badge-warning {
    background: rgba(210, 153, 34, 0.2);
    color: var(--warning-color);
    border: 1px solid var(--warning-color);
}

.badge-danger {
    background: rgba(248, 81, 73, 0.2);
    color: var(--error-color);
    border: 1px solid var(--error-color);
}

.badge-info {
    background: var(--highlight-blue);
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
}

/* Organization Styles */
.org-header {
    position: relative;
    margin-bottom: 2rem;
    background: var(--card-bg);
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid var(--border-subtle);
}

.org-banner {
    width: 100%;
    height: 250px;
    object-fit: cover;
    display: block;
    position: relative;
}

.org-logo-wrapper {
    position: absolute;
    top: -60px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 2;
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.org-logo {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    border: 3px solid var(--border-color);
    object-fit: cover;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.5);
    background: var(--card-bg);
    animation: org-logo-pulse 2.2s infinite cubic-bezier(0.4,0,0.2,1);
    will-change: transform, box-shadow, opacity;
}

@keyframes org-logo-pulse {
  0% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(17,171,233,0.3);
    opacity: 1;
  }
  50% {
    transform: scale(1.07);
    box-shadow: 0 0 16px 4px rgba(17,171,233,0.18);
    opacity: 0.92;
  }
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 rgba(17,171,233,0.3);
    opacity: 1;
  }
}

.org-title-section {
    position: relative;
    padding-top: 70px;
    text-align: center;
}

.org-title-section h1 {
    margin: 0;
    border: none;
    padding: 0;
    font-size: 2rem;
    color: var(--primary-color);
    text-align: center;
    letter-spacing: 1.5px;
    font-weight: 700;
    margin-bottom: 0.5em;
}

.org-quick-info {
    display: flex;
    justify-content: center;
    gap: 1.2em;
    margin-top: 1em;
    flex-wrap: wrap;
}

.org-quick-info span,
.org-quick-info .badge {
    display: inline-flex;
    align-items: center;
    padding: 0.5em 1.2em;
    border-radius: 20px;
    font-size: 1em;
    font-weight: 600;
    background: linear-gradient(90deg, var(--highlight-blue), var(--card-hover));
    color: var(--secondary-color);
    border: 1px solid var(--border-color);
    box-shadow: 0 2px 8px rgba(17,171,233,0.08);
    transition: background 0.3s, color 0.3s;
    margin-bottom: 0.5em;
}

.org-quick-info .badge-owner {
    background: linear-gradient(90deg, var(--success-color), var(--highlight-blue));
    color: #fff;
    border: 1px solid var(--success-color);
}

.org-info-bar {
    padding: 1.5rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
    background: linear-gradient(180deg, var(--dark-bg) 0%, var(--card-bg) 100%);
    border-top: 1px solid var(--border-color);
}

.org-meta {
    display: flex;
    gap: 1.5rem;
    margin-top: 0.5rem;
    flex-wrap: wrap;
}

.org-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-muted);
    font-size: 0.9rem;
}

.org-meta-item strong {
    color: var(--text-primary);
}

/* Tabs */
.tabs-container {
    margin-top: 2rem;
}

.tabs-nav {
    display: flex;
    gap: 0.5rem;
    border-bottom: 2px solid var(--border-subtle);
    margin-bottom: 2rem;
    overflow-x: auto;
}

.tab-btn {
    padding: 1rem 1.5rem;
    background: transparent;
    border: none;
    color: var(--text-muted);
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.tab-btn:hover {
    color: var(--text-secondary);
    background: var(--highlight-blue);
}

.tab-btn.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
    background: var(--highlight-blue);
}

.tab-content {
    display: none;
    animation: fadeIn 0.3s ease;
}

.tab-content.active {
    display: block;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Activities Grid */
.activities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
}

.activity-card {
    background: var(--dark-bg);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
    text-align: center;
    transition: all 0.3s ease;
}

.activity-card:hover {
    border-color: var(--border-color);
    transform: translateY(-4px);
    box-shadow: 0 8px 20px rgba(17, 171, 233, 0.2);
}

.activity-card h3 {
    color: var(--primary-color);
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.activity-card p {
    color: var(--text-secondary);
    font-size: 1.1rem;
}

/* Contact Grid */
.contact-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 1rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1rem;
    background: var(--dark-bg);
    border-radius: 6px;
    border: 1px solid var(--border-subtle);
    transition: all 0.3s ease;
}

.contact-item:hover {
    border-color: var(--primary-color);
    background: var(--highlight-blue);
}

.contact-item strong {
    color: var(--text-primary);
    min-width: 100px;
}

.contact-item a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.contact-item a:hover {
    color: var(--secondary-color);
    text-decoration: underline;
}

/* Members List */
.members-list {
    display: grid;
    gap: 1rem;
}

.member-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: var(--dark-bg);
    border-radius: 6px;
    border: 1px solid var(--border-subtle);
    transition: all 0.3s ease;
}

.member-card:hover {
    background: var(--highlight-blue);
    border-color: var(--border-color);
}

.member-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.member-name {
    font-weight: 600;
    color: var(--text-primary);
}

.role-badge {
    padding: 0.4rem 0.8rem;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    border: 1px solid;
}

/* Diplomacy Relations */
.relations-list {
    display: grid;
    gap: 1rem;
}

.relation-card {
    padding: 1.5rem;
    background: var(--dark-bg);
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.relation-card.alliance {
    border-left: 4px solid var(--success-color);
}

.relation-card.trade_agreement {
    border-left: 4px solid var(--warning-color);
}

.relation-card.war {
    border-left: 4px solid var(--error-color);
}

/* Diplomatie-Logo CSS */
.relation-logos {
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
}
.relation-logo {
    width: 48px;
    height: 48px;
    object-fit: contain;
    border-radius: 8px;
    border: 2px solid #ccc;
    background: #fff;
    margin: 0 4px;
}
.relation-vs {
    font-weight: bold;
    font-size: 1.2em;
    color: #333;
    margin: 0 4px;
}

/* Role Management */
.role-form {
    max-width: 800px;
    margin-bottom: 3rem;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
}

.permissions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1.5rem;
    padding: 1.5rem;
    background: var(--dark-bg);
    border-radius: 6px;
    border: 1px solid var(--border-subtle);
}

.permissions-grid label {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 0.5rem;
    border-radius: 4px;
    transition: all 0.3s ease;
    text-transform: none;
    font-size: 0.9rem;
}

.permissions-grid label:hover {
    background: var(--highlight-blue);
    color: var(--text-primary);
}

.permissions-grid input[type="checkbox"] {
    width: auto;
    cursor: pointer;
    accent-color: var(--primary-color);
}

.roles-list,
.role-list {
    display: grid;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.role-card,
.role-item {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
    transition: all 0.3s ease;
}

.role-card:hover,
.role-item:hover {
    background: var(--card-hover);
    border-color: var(--border-color);
}

.role-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid var(--border-subtle);
}

.role-order {
    color: var(--text-muted);
    font-size: 0.9rem;
    font-weight: 600;
}

.role-info h3 {
    margin: 0 0 0.5rem 0;
    font-size: 1.1rem;
}

.role-card p,
.role-item p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.role-permissions {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin: 1rem 0;
}

.permission-badge,
.perm-badge {
    padding: 0.4rem 0.8rem;
    background: var(--highlight-blue);
    border: 1px solid var(--border-color);
    border-radius: 4px;
    font-size: 0.75rem;
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.85rem;
    background: var(--error-color);
    color: var(--text-primary);
    border: 1px solid var(--error-color);
    margin-top: 0.5rem;
    border-radius: 6px;
    cursor: pointer;
}

/* News Feed */
.news-feed {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 2rem;
}

.news-card {
    display: block;
    background: var(--card-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    box-shadow: 0 4px 16px rgba(17, 171, 233, 0.08);
}

.news-card:hover {
    background: var(--card-hover);
    border-color: var(--border-color);
    box-shadow: 0 8px 24px rgba(17, 171, 233, 0.15);
}

.news-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.5rem;
}

.news-type-badge {
    background: var(--primary-color);
    color: #fff;
    padding: 0.2em 0.7em;
    border-radius: 4px;
    font-size: 0.9em;
    font-weight: 600;
    margin-right: 0.5em;
}
.news-type-admin_news .news-type-badge {
    background: #ff9800;
    color: #fff;
    border: 1px solid #ff9800;
    box-shadow: 0 0 8px #ff980055;
}

.news-date {
    color: var(--text-muted);
    font-size: 0.9em;
}

.news-card h3 {
    font-size: 1.3rem;
    color: var(--secondary-color);
    margin-bottom: 0.5rem;
}

.news-card p {
    color: var(--text-secondary);
    margin-bottom: 0.7rem;
}

.news-footer {
    margin-top: 1rem;
    text-align: right;
}

.news-footer a {
    color: var(--accent-color);
    text-decoration: underline;
    font-size: 0.95em;
}

.btn-link {
    color: var(--primary-color);
    background: none;
    border: none;
    padding: 0;
    font-size: 1em;
    text-decoration: underline;
    cursor: pointer;
}

/* News View & Comments */
.news-view-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 2rem 0;
}

.news-view-card {
    background: var(--card-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 2rem;
    margin-bottom: 2rem;
}

.news-view-meta {
    color: var(--text-muted);
    font-size: 0.95em;
    margin-bottom: 1rem;
    display: flex;
    gap: 1em;
}

.news-view-content {
    color: var(--text-secondary);
    font-size: 1.1em;
    margin-top: 1rem;
}

.news-comments-section {
    display: block;
    background: var(--card-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 1.5rem;
}

.news-comment {
    background: var(--card-hover);
    border-radius: 6px;
    padding: 1rem;
    margin-bottom: 1rem;
}

.news-comment.reply {
    margin-left: 2rem;
    background: #181c24;
}

.comment-meta {
    color: var(--text-muted);
    font-size: 0.9em;
    margin-bottom: 0.5rem;
    display: flex;
    gap: 1em;
}

.comment-content {
    color: var(--text-secondary);
    margin-bottom: 0.5rem;
}

.comment-actions {
    margin-top: 0.5rem;
}

.comment-actions .reply-btn {
    color: var(--accent-color);
    font-size: 0.95em;
    text-decoration: underline;
    background: none;
    border: none;
    cursor: pointer;
}

.comment-replies {
    margin-top: 0.5rem;
}

.news-comments-section form {
    margin-top: 2rem;
}

.news-comments-section textarea {
    width: 100%;
    min-height: 60px;
    border-radius: 4px;
    border: 1px solid var(--border-subtle);
    background: #181c24;
    color: var(--text-primary);
    padding: 0.7em;
    font-size: 1em;
}

.news-comments-section button {
    margin-top: 0.7em;
}

/* Organization News Tab */
.org-news-list {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.org-news-card {
    display: block;
    background: var(--card-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 1.2rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.org-news-card:hover {
    background: var(--card-hover);
    border-color: var(--border-color);
}

.org-news-meta {
    color: var(--text-muted);
    font-size: 0.9em;
    margin-bottom: 0.5rem;
    display: flex;
    gap: 1em;
}

.org-news-content {
    color: var(--text-secondary);
    font-size: 1em;
    margin-bottom: 0.7rem;
}

.org-news-card .btn-link {
    margin-top: 0.5em;
}

/* Footer */
.footer {
    width: 100%;
    font-size: 12px;
    background: rgb(24 28 36 / 0.40);
    color: var(--text-muted);
    padding: 2rem 0 1rem 0;
    border-top: 2px solid var(--border-subtle);
    text-align: center;
    flex-shrink: 0;
    position: relative;
    left: 0;
    bottom: 0;
    z-index: 100;
}

.footer .container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

/* Admin Dashboard Styles */
.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 2rem;
    margin-bottom: 2rem;
}
.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--border-subtle);
    border-radius: 8px;
    padding: 2rem 1.5rem;
    text-align: center;
    box-shadow: 0 4px 16px rgba(17, 171, 233, 0.08);
    transition: all 0.3s ease;
}
.stat-card:hover {
    background: var(--card-hover);
    border-color: var(--border-color);
    box-shadow: 0 8px 24px rgba(17, 171, 233, 0.15);
}
.stat-card h3 {
    color: var(--primary-color);
    font-size: 1.2rem;
    margin-bottom: 0.7rem;
}
.stat-value {
    font-size: 2.2rem;
    font-weight: bold;
    color: var(--secondary-color);
    margin-bottom: 1rem;
}
.admin-logs-table {
    background: var(--card-bg);
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
    padding: 1.5rem;
    margin-top: 2rem;
    overflow-x: auto;
}
.admin-logs-table table {
    width: 100%;
    border-collapse: collapse;
}
.admin-logs-table th, .admin-logs-table td {
    padding: 1rem;
    text-align: left;
    color: var(--text-secondary);
    border-bottom: 1px solid var(--border-subtle);
}
.admin-logs-table th {
    color: var(--primary-color);
    font-weight: 600;
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 1px;
    border-bottom: 2px solid var(--border-color);
}
.admin-logs-table tr:hover {
    background: var(--highlight-blue);
}
.admin-logs-table .badge {
    background: var(--highlight-blue);
    color: var(--primary-color);
    border: 1px solid var(--primary-color);
    padding: 0.3em 0.7em;
    border-radius: 4px;
    font-size: 0.85em;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
@media (max-width: 700px) {
    .admin-stats {
        grid-template-columns: 1fr;
        gap: 1rem;
    }
    .stat-card {
        padding: 1rem;
    }
    .admin-logs-table th, .admin-logs-table td {
        padding: 0.5rem;
    }
}

/* Profile Page Styles */
.profile-page-container {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    max-width: 900px;
    margin: 0 auto;
    padding: 2rem 0;
}

.profile-card {
    background: var(--card-bg);
    border-radius: 12px;
    box-shadow: 0 8px 32px rgba(17,171,233,0.08);
    padding: 2.5rem 2rem;
    display: flex;
    flex-direction: column;
    align-items: center;
    border: 1px solid var(--border-subtle);
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 2rem;
    margin-bottom: 1.5rem;
}

.profile-image {
    flex-shrink: 0;
}

.profile-main-info {
    display: flex;
    flex-direction: column;
    gap: 0.7rem;
}

.profile-main-info h2 {
    color: var(--primary-color);
    font-size: 2rem;
    margin-bottom: 0.2em;
}

.profile-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.2em;
    color: var(--text-muted);
    font-size: 1em;
}

.profile-details {
    width: 100%;
    margin-top: 1.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.profile-detail {
    background: var(--card-hover);
    border-radius: 8px;
    padding: 1rem;
    color: var(--text-secondary);
    font-size: 1.05em;
}

.profile-bio-text {
    margin-top: 0.5em;
    color: var(--text-primary);
    font-size: 1.1em;
    line-height: 1.6;
}

.profile-actions {
    margin-top: 2rem;
    width: 100%;
    text-align: center;
}

.profile-org-section {
    margin-top: 2rem;
}

.profile-org-section h3 {
    color: var(--secondary-color);
    font-size: 1.3rem;
    margin-bottom: 1rem;
}

.profile-placeholder {
    background: #181c24;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 2.5em;
    width: 120px;
    height: 120px;
    border-radius: 50%;
    box-shadow: 0 4px 16px rgba(17,171,233,0.15);
}

@media (max-width: 700px) {
    .profile-page-container {
        padding: 1rem 0;
    }
    .profile-card {
        padding: 1rem;
    }
    .profile-header {
        flex-direction: column;
        gap: 1rem;
    }
}

/* Responsive */
@media (max-width: 700px) {
    .news-feed {
        grid-template-columns: 1fr;
    }
    .news-view-container {
        padding: 1rem 0;
    }
    .org-news-list {
        gap: 0.7rem;
    }
    .footer {
        padding: 1rem 0 0.5rem 0;
    }
}

@media (max-width: 900px) {
    body {
        background-size: cover;
        background-position: center top;
    }
}
@media (max-width: 600px) {
    body {
        background-size: cover;
        background-position: center top;
    }
}

/* Scrollbar Styling */
::-webkit-scrollbar {
    width: 12px;
    height: 12px;
}

::-webkit-scrollbar-track {
    background: var(--dark-bg);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: 6px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--primary-color);
}

/* Selection */
::selection {
    background: var(--highlight-blue);
    color: var(--primary-color);
}

/* Loading Animation */
@keyframes pulse {
    0%, 100% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
}

.loading {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* Organizations List */
.organizations-list {
    display: grid;
    gap: 1.5rem;
    margin-top: 2rem;
}

.organization-card {
    background: var(--card-bg);
    padding: 1.5rem;
    border-radius: 8px;
    border: 1px solid var(--border-subtle);
    transition: all 0.3s ease;
}

.organization-card:hover {
    background: var(--card-hover);
    border-color: var(--border-color);
    transform: translateX(5px);
}

.organization-card h3 {
    margin-bottom: 0.75rem;
}

.organization-card h3 a {
    color: var(--primary-color);
    text-decoration: none;
    transition: color 0.3s ease;
}

.organization-card h3 a:hover {
    color: var(--secondary-color);
}

.organization-card p {
    color: var(--text-secondary);
    margin-bottom: 1rem;
    line-height: 1.6;
}

.organization-card .org-meta {
    display: flex;
    gap: 1.5rem;
    flex-wrap: wrap;
    padding-top: 0.75rem;
    border-top: 1px solid var(--border-subtle);
    font-size: 0.9rem;
}

/* Diplomatie-Icons als Floating-Icons oben rechts im Header */
.org-menu-header-icons {
  position: absolute;
  top: 0.7em;
  right: 2em;
  display: flex;
  gap: 1em;
  z-index: 10;
}
.org-menu-header-icons .org-icon {
  font-size: 2em;
  background: #232a36;
  border-radius: 50%;
  padding: 0.25em 0.35em;
  box-shadow: 0 2px 8px #0002;
  color: #11abe9;
  position: relative;
}
.org-menu-header-icons .org-badge {
  background: #e11a1a;
  color: #fff;
  border-radius: 12px;
  padding: 0.2em 0.7em;
  font-size: 0.9em;
  font-weight: bold;
  position: absolute;
  top: -8px;
  right: -8px;
}
.org-menu-header-icons a {
  display: inline-block;
  position: relative;
  text-decoration: none;
}
@media (max-width: 900px) {
  .org-menu-header-icons {
    right: 0.5em;
    top: 0.5em;
  }
}

/* Mailbox Design */
.mailbox {
    display: flex;
    flex-direction: column;
    gap: 1.2em;
    margin-top: 1em;
}
.mail-item {
    display: flex;
    align-items: flex-start;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 2px 12px #232a3640;
    padding: 1.2em 1.5em;
    transition: box-shadow 0.2s, background 0.2s, transform 0.2s;
    border: 1px solid #e3e7ef;
    position: relative;
    min-height: 90px;
}
.mail-item.mail-unread {
    background: #f5faff;
    border-left: 6px solid #11abe9;
    box-shadow: 0 6px 24px #11abe940;
}
.mail-item.mail-read {
    background: #f7f7f7;
    border-left: 6px solid #e3e7ef;
}
.mail-item:hover {
    box-shadow: 0 8px 32px #11abe980;
    background: #eaf6ff;
    transform: scale(1.02);
}
.mail-avatar {
    flex-shrink: 0;
    margin-right: 1.2em;
    margin-top: 0.2em;
}
.mail-avatar-circle {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #11abe9;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.3em;
    font-weight: bold;
    box-shadow: 0 2px 8px #11abe940;
    border: 2px solid #fff;
}
.mail-content {
    flex: 1 1 auto;
    display: flex;
    flex-direction: column;
    gap: 0.3em;
}
.mail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 0.5em;
}
.mail-status .material-icons {
    font-size: 1.5em;
    color: #11abe9;
    vertical-align: middle;
}
.mail-from {
    font-weight: 500;
    color: #232a36;
    margin-left: 0.7em;
}
.mail-date {
    color: #888;
    font-size: 0.95em;
}
.mail-subject {
    font-size: 1.2em;
    font-weight: bold;
    color: #232a36;
    margin-bottom: 0.3em;
}
.mail-preview {
    color: #555;
    font-size: 1em;
    margin-bottom: 0.7em;
}
.mail-actions {
    display: flex;
    gap: 0.7em;
    margin-top: 0.2em;
}
.mail-action.mail-action-round {
    background: #f5faff;
    border-radius: 50%;
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px #11abe940;
    transition: background 0.2s, color 0.2s;
    position: relative;
}
.mail-action.mail-action-round:hover {
    background: #11abe9;
}
.mail-action.mail-action-round .material-icons {
    font-size: 1.3em;
    color: #11abe9;
    transition: color 0.2s;
}
.mail-action.mail-action-round:hover .material-icons {
    color: #fff;
}
.mail-checkbox {
    position: absolute;
    left: 1em;
    top: 1em;
}
.mail-item {
    padding-left: 3em;
}
@media (max-width: 700px) {
    .mail-item { flex-direction: column; align-items: stretch; padding: 0.7em 0.5em; }
    .mail-avatar { margin-right: 0.7em; }
    .mail-header { flex-direction: column; align-items: flex-start; gap: 0.3em; }
    .mail-subject { font-size: 1em; }
    .mail-preview { font-size: 0.95em; }
}

/* Sterne-Bewertung */
.org-stars {
    display: inline-flex;
    flex-direction: row;
    gap: 2px;
    font-size: 1.5em;
    color: #ffcc00;
    position: relative;
}
.org-stars input[type="radio"] {
    display: none;
}
.org-stars label {
    cursor: pointer;
    user-select: none;
    color: #bbb;
    transition: color 0.2s;
    font-size: 1.5em;
    padding: 0 2px;
    z-index: 1;
}
.org-stars label:before {
    content: '★';
}
.org-stars input[type="radio"]:checked ~ label {
    color: #ffd900;
}
.org-stars input[type="radio"]:checked ~ label,
.org-stars input[type="radio"]:checked {
    color: #ffd900;
}
.org-stars input[type="radio"]:checked + label,
.org-stars input[type="radio"]:checked + label ~ label {
    color: #ffffff !important;
}
.org-stars label:hover,
.org-stars label:hover ~ label {
    color: #ffffff !important;
}
.org-list-header {
    display: flex;
    align-items: center;
    gap: 1.2em;
    margin-bottom: 0.7em;
}
.org-list-logo-wrapper {
    width: 54px;
    height: 54px;
    border-radius: 50%;
    background: #232a36;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    box-shadow: 0 2px 8px #11abe930;
    border: 2px solid #11abe9;
}
.org-list-logo {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: 50%;
    background: #fff;
}
.org-list-logo-placeholder {
    color: #fff;
    font-size: 2em;
    font-weight: bold;
    background: #11abe9;
    border: 2px solid #38d9ff;
}

