/*
Theme Name: MemberSphere Theme
Theme URI: https://membersphere.dev
Author: MemberSphere Team
Author URI: https://membersphere.dev
Description: Das offizielle Theme für MemberSphere - Deine Community-Plattform. Minimalistisches Design mit zentriertem Layout.
Version: 1.2.6
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 8.0
License: GPL-2.0-or-later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: membersphere-theme
Domain Path: /languages
Tags: community, courses, forum, members, social-network, custom-colors, custom-logo, custom-menu, featured-images, threaded-comments, translation-ready

MemberSphere Theme ist speziell für das MemberSphere Plugin entwickelt.
Es bietet alle nötigen Templates und Styles für eine vollständige Community-Plattform.
*/

/* ==========================================================================
   CSS Custom Properties (Defaults - werden vom Customizer überschrieben)
   ========================================================================== */

:root {
    /* Farben */
    --ms-primary: #4F46E5;
    --ms-primary-hover: #4338CA;
    --ms-primary-rgb: 79, 70, 229;
    --ms-secondary: #10B981;
    --ms-secondary-hover: #059669;
    
    /* Semantic Colors */
    --ms-success: #10B981;
    --ms-warning: #F59E0B;
    --ms-danger: #EF4444;
    --ms-info: #3B82F6;
    
    /* Text */
    --ms-text-color: #1F2937;
    --ms-text-light: #6B7280;
    --ms-text-lighter: #9CA3AF;
    
    /* Hintergründe */
    --ms-bg-body: #F9FAFB;
    --ms-bg-white: #FFFFFF;
    --ms-bg-gray: #F3F4F6;
    
    /* Header */
    --ms-header-bg: #FFFFFF;
    --ms-header-text: #1F2937;
    --ms-header-height: 70px;
    
    /* Footer */
    --ms-footer-bg: #1F2937;
    --ms-footer-text: #F9FAFB;
    
    /* Borders */
    --ms-border-color: #E5E7EB;
    --ms-border-radius-sm: 4px;
    --ms-border-radius: 8px;
    --ms-border-radius-lg: 12px;
    
    /* Shadows */
    --ms-shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
    --ms-shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --ms-shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
    --ms-shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -4px rgba(0, 0, 0, 0.1);
    
    /* Typografie */
    --ms-font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen-Sans, Ubuntu, Cantarell, "Helvetica Neue", sans-serif;
    --ms-font-family-headings: var(--ms-font-family);
    --ms-font-size-base: 16px;
    --ms-line-height: 1.6;
    
    /* Font Sizes */
    --ms-text-xs: 0.75rem;
    --ms-text-sm: 0.875rem;
    --ms-text-base: 1rem;
    --ms-text-lg: 1.125rem;
    --ms-text-xl: 1.25rem;
    --ms-text-2xl: 1.5rem;
    --ms-text-3xl: 1.875rem;
    --ms-text-4xl: 2.25rem;
    
    /* Spacing */
    --ms-spacing-xs: 0.25rem;
    --ms-spacing-sm: 0.5rem;
    --ms-spacing-md: 1rem;
    --ms-spacing-lg: 1.5rem;
    --ms-spacing-xl: 2rem;
    --ms-spacing-2xl: 3rem;
    --ms-spacing-3xl: 4rem;
    
    /* Container */
    --ms-container-width: 1200px;
    --ms-container-narrow: 800px;
    --ms-container-wide: 1400px;
    --ms-container-padding: 1rem;
    
    /* Transitions */
    --ms-transition: 150ms ease-in-out;
    --ms-transition-slow: 300ms ease-in-out;
    
    /* Z-Index Scale */
    --ms-z-dropdown: 1000;
    --ms-z-sticky: 1020;
    --ms-z-fixed: 1030;
    --ms-z-modal-backdrop: 1040;
    --ms-z-modal: 1050;
    --ms-z-popover: 1060;
    --ms-z-tooltip: 1070;
}

/* ==========================================================================
   CSS Reset (Modern Minimal)
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
}

* {
    margin: 0;
    padding: 0;
}

html {
    font-size: var(--ms-font-size-base);
    scroll-behavior: smooth;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: var(--ms-font-family);
    font-size: 1rem;
    line-height: var(--ms-line-height);
    color: var(--ms-text-color);
    background-color: var(--ms-bg-body);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

input,
button,
textarea,
select {
    font: inherit;
    color: inherit;
}

p,
h1,
h2,
h3,
h4,
h5,
h6 {
    overflow-wrap: break-word;
}

h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--ms-font-family-headings);
    font-weight: 600;
    line-height: 1.3;
    color: var(--ms-text-color);
}

a {
    color: var(--ms-primary);
    text-decoration: none;
    transition: color var(--ms-transition);
}

a:hover,
a:focus {
    color: var(--ms-primary-hover);
    text-decoration: underline;
}

ul,
ol {
    list-style-position: inside;
}

/* Remove default button styles */
button {
    background: none;
    border: none;
    cursor: pointer;
}

/* Remove default fieldset styles */
fieldset {
    border: none;
}

/* Accessibility: Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ==========================================================================
   WordPress Core Styles
   ========================================================================== */

/* Alignments */
.alignleft {
    float: left;
    margin-right: var(--ms-spacing-lg);
    margin-bottom: var(--ms-spacing-md);
}

.alignright {
    float: right;
    margin-left: var(--ms-spacing-lg);
    margin-bottom: var(--ms-spacing-md);
}

.aligncenter {
    display: block;
    margin-left: auto;
    margin-right: auto;
    margin-bottom: var(--ms-spacing-md);
}

.alignwide {
    max-width: var(--ms-container-wide);
    margin-left: auto;
    margin-right: auto;
}

.alignfull {
    width: 100%;
    max-width: 100%;
    margin-left: 0;
    margin-right: 0;
}

/* Captions */
.wp-caption {
    max-width: 100%;
    margin-bottom: var(--ms-spacing-md);
}

.wp-caption img {
    display: block;
    margin: 0 auto;
}

.wp-caption-text {
    font-size: 0.875rem;
    color: var(--ms-text-light);
    text-align: center;
    padding: var(--ms-spacing-sm);
}

/* Galleries */
.gallery {
    display: grid;
    grid-gap: var(--ms-spacing-md);
    margin-bottom: var(--ms-spacing-lg);
}

.gallery-columns-2 { grid-template-columns: repeat(2, 1fr); }
.gallery-columns-3 { grid-template-columns: repeat(3, 1fr); }
.gallery-columns-4 { grid-template-columns: repeat(4, 1fr); }
.gallery-columns-5 { grid-template-columns: repeat(5, 1fr); }

.gallery-item {
    margin: 0;
}

.gallery-icon img {
    width: 100%;
    height: auto;
}

/* Screen Reader Text */
.screen-reader-text {
    border: 0;
    clip: rect(1px, 1px, 1px, 1px);
    clip-path: inset(50%);
    height: 1px;
    margin: -1px;
    overflow: hidden;
    padding: 0;
    position: absolute !important;
    width: 1px;
    word-wrap: normal !important;
}

.screen-reader-text:focus {
    background-color: var(--ms-bg-white);
    border-radius: var(--ms-border-radius);
    box-shadow: var(--ms-shadow-lg);
    clip: auto !important;
    clip-path: none;
    color: var(--ms-primary);
    display: block;
    font-size: 0.875rem;
    font-weight: 600;
    height: auto;
    left: 5px;
    line-height: normal;
    padding: var(--ms-spacing-md) var(--ms-spacing-lg);
    text-decoration: none;
    top: 5px;
    width: auto;
    z-index: 100000;
}

/* Skip Link */
.skip-link {
    position: absolute;
    top: -100px;
    left: 0;
    background: var(--ms-primary);
    color: #fff;
    padding: var(--ms-spacing-sm) var(--ms-spacing-md);
    z-index: 100000;
    transition: top var(--ms-transition);
}

.skip-link:focus {
    top: 0;
    color: #fff;
    text-decoration: none;
}
