/* ============================================
   KIRChenglocken Rechner - Stylesheet
   ============================================ */

/* Reset & Base */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, sans-serif;
    background: #f5f5f4;
    color: #44403c;
    line-height: 1.6;
}

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

/* ============================================
   HEADER
   ============================================ */
header {
    text-align: center;
    padding: 40px 20px;
    background: linear-gradient(135deg, #722F37 0%, #9B2335 100%);
    color: white;
    border-radius: 16px;
    margin-bottom: 30px;
}

header h1 {
    font-size: 2.5rem;
    margin-bottom: 10px;
}

header p {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* ============================================
   NAVIGATION
   ============================================ */
.nav {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.nav button {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 600;
    transition: all 0.3s;
}

.nav button.active {
    background: #722F37;
    color: white;
}

.nav button:not(.active) {
    background: white;
    color: #722F37;
}

.nav button:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
}

/* ============================================
   SECTIONS
   ============================================ */
.section {
    background: white;
    border-radius: 16px;
    padding: 30px;
    margin-bottom: 20px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.section h2 {
    color: #722F37;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.section p {
    color: #78716c;
    margin-bottom: 20px;
}

/* ============================================
   FORM ELEMENTS
   ============================================ */
.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.form-group {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.form-group label {
    font-weight: 600;
    color: #57534e;
}

select,
input[type="number"] {
    padding: 12px;
    border: 2px solid #e7e5e4;
    border-radius: 8px;
    font-size: 1rem;
    background: white;
    width: 100%;
}

select:focus,
input:focus {
    outline: none;
    border-color: #8B1E3F;
}

input[type="range"] {
    padding: 0;
    height: 8px;
    -webkit-appearance: none;
    appearance: none;
    background: #e7e5e4;
    border-radius: 4px;
    width: 100%;
    margin-top: 8px;
}

input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    width: 20px;
    height: 20px;
    background: #722F37;
    border-radius: 50%;
    cursor: pointer;
}

small {
    color: #78716c;
    font-size: 0.85rem;
}

/* ============================================
   TONE SELECTOR
   ============================================ */
.tone-selector {
    display: flex;
    gap: 8px;
}

.tone-selector select {
    flex: 1;
}

.tone-selector select:first-child {
    flex: 2;
}

.tone-selector select:nth-child(2) {
    width: 70px;
    flex: none;
}

.tone-selector select:nth-child(3) {
    width: 90px;
    flex: none;
}

/* ============================================
   RESULTS
   ============================================ */
.results {
    background: #fafaf9;
    border-radius: 12px;
    padding: 25px;
    margin-top: 20px;
}

.results h3 {
    color: #722F37;
    margin-bottom: 20px;
}

/* ============================================
   TABLES
   ============================================ */
table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 15px;
}

th, td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #e7e5e4;
}

th {
    background: #fafaf9;
    font-weight: 600;
    color: #57534e;
}

tr:hover {
    background: #fafaf9;
}

/* ============================================
   BADGES
   ============================================ */
.note-badge {
    display: inline-block;
    padding: 4px 12px;
    background: #ddd6fe;
    color: #5b21b6;
    border-radius: 20px;
    font-weight: 600;
}

/* ============================================
   RIPPENSTÄRKE DISPLAY
   ============================================ */
.rs-display {
    text-align: center;
    padding: 30px;
}

.rs-value {
    font-size: 4rem;
    font-weight: bold;
    margin-bottom: 10px;
}

.rs-classification {
    font-size: 1.5rem;
    font-weight: 600;
}

.rs-scale {
    margin-top: 20px;
    background: #e7e5e4;
    height: 12px;
    border-radius: 6px;
    position: relative;
}

.rs-scale-gradient {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6 0%, #3b82f6 30%, #16a34a 50%, #eab308 70%, #ef4444 100%);
    border-radius: 6px;
}

.rs-marker {
    position: absolute;
    top: -4px;
    width: 4px;
    height: 20px;
    background: black;
    border: 2px solid white;
    border-radius: 2px;
    transform: translateX(-50%);
}

.rs-scale-labels {
    display: flex;
    justify-content: space-between;
    margin-top: 5px;
    font-size: 0.8rem;
    color: #78716c;
}

/* ============================================
   CALCULATION DETAILS
   ============================================ */
.calculation-details {
    background: #fafaf9;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
}

.calc-row {
    display: flex;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #e7e5e4;
}

.calc-row:last-child {
    border-bottom: none;
    font-weight: 600;
    color: #722F37;
}

/* ============================================
   INFO BOXES
   ============================================ */
.info-box {
    background: #dbeafe;
    border: 1px solid #93c5fd;
    border-radius: 8px;
    padding: 15px;
    margin-top: 20px;
}

.info-box h4 {
    color: #1e40af;
    margin-bottom: 8px;
}

.info-box p {
    color: #1e40af;
    font-size: 0.9rem;
    margin-bottom: 0;
}

.info-box.warning {
    background: #fce7f3;
    border-color: #f9a8d4;
}

.info-box.warning h4,
.info-box.warning p {
    color: #9d174d;
}

/* ============================================
   TOP NAVBAR
   ============================================ */
.top-navbar {
    background: white;
    padding: 15px 20px;
    margin: 20px auto 30px;
    max-width: 1200px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.top-navbar ul {
    list-style: none;
    display: flex;
    justify-content: center;
    gap: 10px;
    margin: 0;
    padding: 0;
    flex-wrap: wrap;
}

.top-navbar li {
    margin: 0;
}

.top-navbar a {
    display: block;
    color: #57534e;
    text-decoration: none;
    padding: 10px 20px;
    border-radius: 8px;
    transition: all 0.3s;
    font-weight: 500;
}

.top-navbar a:hover {
    background: #fafaf9;
    color: #722F37;
}

.top-navbar a.active {
    background: #722F37;
    color: white;
}

/* Dropdown Menu */
.dropdown {
    position: relative;
}

.dropdown-content {
    display: none;
    position: absolute;
    background: white;
    min-width: 220px;
    box-shadow: 0 8px 16px rgba(0,0,0,0.15);
    border-radius: 8px;
    top: 100%;
    left: 50%;
    transform: translateX(-50%);
    z-index: 100;
    overflow: hidden;
    padding-top: 10px;
    margin-top: 0;
}

.dropdown-content a {
    padding: 14px 24px;
    border-radius: 0;
    border-bottom: 1px solid #f0f0f0;
    font-size: 0.95rem;
    background: white;
}

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

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

.dropdown:hover > a {
    background: #fafaf9;
    color: #722F37;
}

.dropdown > a::after {
    content: " ▼";
    font-size: 0.7em;
}

/* ============================================
   BREADCRUMB
   ============================================ */
.breadcrumb {
    font-size: 0.8rem;
    opacity: 0.8;
    margin-bottom: 15px;
}

.breadcrumb a {
    color: white;
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb span {
    margin: 0 5px;
}

/* ============================================
   INTRO / LANDING PAGE
   ============================================ */
.intro {
    text-align: center;
    max-width: 600px;
    margin: 0 auto 40px;
}

.intro h2 {
    color: #722F37;
    margin-bottom: 15px;
}

.intro p {
    color: #78716c;
    font-size: 1.1rem;
}

/* ============================================
   PROJECT CARDS
   ============================================ */
.projects-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.project-card {
    background: white;
    border-radius: 16px;
    padding: 30px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
    text-decoration: none;
    color: inherit;
    transition: all 0.3s;
    display: flex;
    flex-direction: column;
    position: relative;
}

.project-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.1);
}

.project-card.coming-soon {
    opacity: 0.7;
    cursor: default;
}

.project-card.coming-soon:hover {
    transform: none;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

.project-icon {
    font-size: 3rem;
    margin-bottom: 15px;
}

.project-card h3 {
    color: #722F37;
    margin-bottom: 15px;
    font-size: 1.4rem;
}

.project-card p {
    color: #78716c;
    margin-bottom: 20px;
    flex-grow: 1;
}

.project-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.tag {
    background: #fafaf9;
    color: #722F37;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.coming-soon-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #722F37;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* ============================================
   FOOTER
   ============================================ */
footer {
    background: linear-gradient(135deg, #722F37 0%, #5a252c 100%);
    color: white;
    padding: 0;
    margin-top: 40px;
}

.footer-main {
    max-width: 1200px;
    margin: 0 auto;
    padding: 40px 30px;
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
}

.footer-section h4 {
    font-size: 1.1rem;
    margin-bottom: 20px;
    padding-bottom: 10px;
    border-bottom: 2px solid rgba(255,255,255,0.2);
    display: inline-block;
}

.footer-section p {
    margin: 8px 0;
    opacity: 0.9;
    line-height: 1.6;
}

.footer-section a {
    color: white;
    text-decoration: none;
    opacity: 0.9;
    display: block;
    padding: 8px 0;
    transition: all 0.3s;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.footer-section a:last-child {
    border-bottom: none;
}

.footer-section a:hover {
    opacity: 1;
    padding-left: 8px;
}

.footer-bottom {
    background: rgba(0,0,0,0.2);
    text-align: center;
    padding: 20px;
    font-size: 0.9rem;
    opacity: 0.8;
}

@media (max-width: 768px) {
    .footer-content {
        flex-direction: column;
    }
    
    .footer-links {
        width: 100%;
        justify-content: center;
    }
}

/* ============================================
   ADMIN STYLES
   ============================================ */
.admin-form {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.form-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

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

.form-group label {
    font-weight: 600;
    margin-bottom: 8px;
    color: #374151;
}

.form-group input,
.form-group select {
    padding: 12px;
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    font-size: 1rem;
    transition: border-color 0.3s;
}

.form-group input:focus,
.form-group select:focus {
    border-color: #722F37;
    outline: none;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.btn-primary {
    background: linear-gradient(135deg, #722F37 0%, #9B2335 100%);
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    transition: transform 0.3s;
}

.btn-primary:hover {
    transform: translateY(-2px);
}

.btn-secondary {
    background: #6b7280;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
}

.admin-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.admin-project-item {
    background: white;
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.admin-project-info h4 {
    color: #722F37;
    margin-bottom: 8px;
}

.admin-project-info p {
    color: #6b7280;
    margin-bottom: 8px;
}

.status-badge-small {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
    color: white;
}

.admin-project-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.btn-edit {
    background: #3b82f6;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-edit:hover {
    background: #2563eb;
    transform: translateY(-1px);
}

.btn-delete {
    background: #ef4444;
    color: white;
    border: none;
    padding: 8px 16px;
    border-radius: 6px;
    cursor: pointer;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-delete:hover {
    background: #dc2626;
    transform: translateY(-1px);
}

/* ============================================
   UTILITIES
   ============================================ */
.hidden {
    display: none;
}

/* ============================================
   RESPONSIVE
   ============================================ */
@media (max-width: 768px) {
    header h1 {
        font-size: 1.8rem;
    }
    
    .section {
        padding: 20px;
    }
    
    .tone-selector {
        flex-wrap: wrap;
    }
    
    .tone-selector select:nth-child(2),
    .tone-selector select:nth-child(3) {
        width: calc(50% - 4px);
    }
    
    .rs-value {
        font-size: 3rem;
    }
    
    .projects-grid {
        grid-template-columns: 1fr;
    }
    
    .project-card {
        padding: 20px;
    }
    
    .breadcrumb {
        font-size: 0.8rem;
    }
}

/* ============================================
   WEIGHT CALCULATOR
   ============================================ */
.calculator-form {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    margin-bottom: 30px;
}

.form-row {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 20px;
}

.btn-calculate {
    background: linear-gradient(135deg, #722F37 0%, #9B2335 100%);
    color: white;
    border: none;
    padding: 15px 30px;
    border-radius: 8px;
    cursor: pointer;
    font-weight: 600;
    font-size: 1.1rem;
    width: 100%;
    transition: all 0.3s;
}

.btn-calculate:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(114, 47, 55, 0.4);
}

.main-result-container {
    margin-bottom: 30px;
}

.methods-container {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.result-card {
    background: white;
    padding: 25px;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    text-align: center;
}

.result-card.main-result {
    background: linear-gradient(135deg, #722F37 0%, #9B2335 100%);
    color: white;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
}

.result-card h3 {
    margin-bottom: 15px;
    color: #374151;
    font-size: 1.1rem;
}

.result-card.main-result h3 {
    color: white;
}

.result-value {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 10px;
    color: #722F37;
}

.result-card.main-result .result-value {
    color: white;
    font-size: 3.5rem;
}

.result-description {
    color: #6b7280;
    font-size: 0.9rem;
    margin: 0;
}

.result-card.main-result .result-description {
    color: rgba(255, 255, 255, 0.9);
}

@media (max-width: 768px) {
    .methods-container {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 480px) {
    .methods-container {
        grid-template-columns: 1fr;
    }
}

/* ============================================
   CHURCH PROJECTS
   ============================================ */
.filter-bar {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-bottom: 25px;
    padding: 15px;
    background: #fafaf9;
    border-radius: 8px;
}

.filter-bar label {
    font-weight: 600;
    color: #57534e;
}

.filter-bar select {
    padding: 8px 15px;
    border: 2px solid #e7e5e4;
    border-radius: 8px;
    background: white;
}

.projects-grid-churches {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 25px;
}

.church-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    transition: transform 0.3s, box-shadow 0.3s;
}

.church-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0,0,0,0.12);
}

.church-image {
    position: relative;
    height: 200px;
    overflow: hidden;
}

.church-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.status-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.church-info {
    padding: 20px;
}

.church-info h3 {
    color: #722F37;
    margin-bottom: 8px;
    font-size: 1.2rem;
}

.church-info .location {
    color: #78716c;
    margin-bottom: 15px;
}

.youtube-link {
    display: inline-block;
    color: #ef4444;
    text-decoration: none;
    font-weight: 500;
}

.youtube-link:hover {
    text-decoration: underline;
}

.no-video {
    color: #9ca3af;
    font-size: 0.9rem;
}

.no-projects {
    text-align: center;
    color: #78716c;
    padding: 40px;
}

/* ============================================
   ADMIN STYLES
   ============================================ */
.admin-form {
    max-width: 800px;
}

.form-actions {
    display: flex;
    gap: 15px;
    margin-top: 25px;
}

.btn-primary, .btn-secondary, .btn-edit, .btn-delete {
    padding: 12px 24px;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s;
}

.btn-primary {
    background: #722F37;
    color: white;
}

.btn-primary:hover {
    background: #8B1E3F;
}

.btn-secondary {
    background: #e7e5e4;
    color: #57534e;
}

.btn-secondary:hover {
    background: #d6d3d1;
}

.admin-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.admin-project-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    background: #fafaf9;
    border-radius: 8px;
    flex-wrap: wrap;
    gap: 15px;
}

.admin-project-info h4 {
    color: #722F37;
    margin-bottom: 5px;
}

.admin-project-info p {
    color: #78716c;
    margin-bottom: 8px;
}

.status-badge-small {
    color: white;
    padding: 3px 10px;
    border-radius: 15px;
    font-size: 0.75rem;
    font-weight: 600;
}

.admin-project-actions {
    display: flex;
    gap: 10px;
}

.btn-edit {
    background: #3b82f6;
    color: white;
    padding: 8px 16px;
}

.btn-edit:hover {
    background: #2563eb;
}

.btn-delete {
    background: #ef4444;
    color: white;
    padding: 8px 16px;
}

.btn-delete:hover {
    background: #dc2626;
}

@media (max-width: 768px) {
    .admin-project-item {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .admin-project-actions {
        width: 100%;
    }
    
    .projects-grid-churches {
        grid-template-columns: 1fr;
    }
}
