/*
Theme Name: Sue Curtis Writer Theme
Theme URI: https://suecurtis.co.uk/
Author: Claude Code Wizard
Author URI: https://suecurtis.co.uk/
Description: Writer, librettist and playwright portfolio theme for Sue Curtis
Version: 1.0.0
License: GPL v2 or later
Text Domain: my-custom-theme
*/

/* ============================================
   ROOT CSS VARIABLES - Design System
   ============================================ */
:root {
    /* Colors */
    --primary: #8b0000;
    --background-light: #f8f6f6;
    --background-dark: #000000;
    --surface-dark: #1A1A1A;
    --primary-gold: #D4AF37;

    /* Text Colors */
    --text-primary-light: #1f2937;
    --text-secondary-light: #6b7280;
    --text-primary-dark: #ffffff;
    --text-secondary-dark: #d1d5db;

    /* Borders */
    --border-light: #e5e7eb;
    --border-dark: #ffffff1a;

    /* Typography */
    --font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    --font-serif: 'Lora', Georgia, serif;

    /* Spacing */
    --spacing-xs: 0.25rem;
    --spacing-sm: 0.5rem;
    --spacing-md: 1rem;
    --spacing-lg: 1.5rem;
    --spacing-xl: 2rem;
    --spacing-2xl: 3rem;
    --spacing-3xl: 4rem;
    --spacing-4xl: 6rem;

    /* Border Radius */
    --radius-sm: 0.25rem;
    --radius-md: 0.5rem;
    --radius-lg: 0.75rem;
    --radius-xl: 1rem;
    --radius-full: 9999px;
}

html.dark {
    color-scheme: dark;
}

/* ============================================
   GLOBAL STYLES
   ============================================ */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--font-family);
    font-size: 16px;
    line-height: 1.6;
    background-color: var(--background-light);
    color: var(--text-primary-light);
    transition: background-color 0.3s ease, color 0.3s ease;
}

html.dark body {
    background-color: var(--background-dark);
    color: var(--text-primary-dark);
}

/* ============================================
   TYPOGRAPHY
   ============================================ */
h1, h2, h3, h4, h5, h6 {
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: var(--spacing-lg);
}

h1 {
    font-size: 2.25rem;
    font-weight: 900;
    letter-spacing: -0.033em;
}

h2 {
    font-size: 1.875rem;
    font-weight: 700;
}

h3 {
    font-size: 1.5rem;
    font-weight: 700;
}

h4 {
    font-size: 1.25rem;
    font-weight: 600;
}

p {
    margin-bottom: var(--spacing-md);
    line-height: 1.6;
}

a {
    color: var(--primary);
    text-decoration: none;
    transition: color 0.2s ease;
}

html.dark a {
    color: var(--text-primary-dark);
}

a:hover {
    color: var(--primary);
    opacity: 0.8;
}

/* ============================================
   BUTTONS
   ============================================ */
.btn, button, input[type="submit"] {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: var(--spacing-md) var(--spacing-lg);
    border: none;
    border-radius: var(--radius-lg);
    font-weight: 700;
    font-size: 1rem;
    cursor: pointer;
    transition: all 0.2s ease;
    text-transform: none;
    letter-spacing: 0.015em;
    text-decoration: none;
    min-height: 2.75rem;
}

.btn-primary, .button-primary, button.primary, input[type="submit"] {
    background-color: var(--primary);
    color: white;
}

.btn-primary:hover, .button-primary:hover, button.primary:hover, input[type="submit"]:hover {
    background-color: color-mix(in srgb, var(--primary) 90%, black);
    box-shadow: 0 4px 12px rgba(17, 50, 212, 0.2);
}

.btn-secondary {
    background-color: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    color: white;
}

.btn-secondary:hover {
    background-color: rgba(255, 255, 255, 0.2);
    border-color: rgba(255, 255, 255, 0.3);
}

/* ============================================
   FORMS
   ============================================ */
input[type="text"],
input[type="email"],
input[type="password"],
input[type="number"],
input[type="url"],
textarea,
select {
    width: 100%;
    padding: var(--spacing-md);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    font-family: var(--font-family);
    font-size: 1rem;
    background-color: white;
    color: var(--text-primary-light);
    transition: all 0.2s ease;
    margin-bottom: var(--spacing-md);
}

html.dark input[type="text"],
html.dark input[type="email"],
html.dark input[type="password"],
html.dark input[type="number"],
html.dark input[type="url"],
html.dark textarea,
html.dark select {
    background-color: var(--background-dark);
    border-color: var(--border-dark);
    color: var(--text-primary-dark);
}

input[type="text"]:focus,
input[type="email"]:focus,
input[type="password"]:focus,
input[type="number"]:focus,
input[type="url"]:focus,
textarea:focus,
select:focus {
    outline: none;
    border-color: var(--primary);
    box-shadow: 0 0 0 2px rgba(17, 50, 212, 0.1);
}

label {
    display: block;
    font-weight: 500;
    margin-bottom: var(--spacing-xs);
    font-size: 0.875rem;
}

/* ============================================
   LAYOUT - HEADER
   ============================================ */
.site-header {
    position: sticky;
    top: 0;
    z-index: 50;
    display: flex;
    align-items: center;
    justify-content: space-between;
    border-bottom: 1px solid var(--border-light);
    background-color: rgba(246, 246, 248, 0.8);
    backdrop-filter: blur(6px);
    padding: var(--spacing-md) var(--spacing-lg);
}

html.dark .site-header {
    border-bottom-color: rgba(255, 255, 255, 0.1);
    background-color: rgba(16, 19, 34, 0.8);
}

.site-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    max-width: 100%;
    padding: 0;
    gap: var(--spacing-lg);
}

.site-title {
    font-size: 1.125rem;
    font-weight: 700;
    margin: 0;
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

.site-title a {
    color: var(--text-primary-light);
    text-decoration: none;
    display: flex;
    align-items: center;
    gap: var(--spacing-md);
}

html.dark .site-title a {
    color: white;
}

.site-logo {
    width: 1.5rem;
    height: 1.5rem;
    color: var(--primary);
}

.site-description {
    display: none;
}

/* Main Navigation */
.main-navigation {
    flex: 1;
    display: flex;
    justify-content: flex-end;
    align-items: center;
    gap: var(--spacing-xl);
}

.primary-menu,
.footer-menu {
    list-style: none;
    display: flex;
    gap: var(--spacing-xl);
    align-items: center;
    margin: 0;
    padding: 0;
}

.primary-menu a,
.footer-menu a {
    color: var(--text-secondary-light);
    font-size: 0.875rem;
    font-weight: 500;
    transition: color 0.2s ease;
    text-decoration: none;
}

html.dark .primary-menu a,
html.dark .footer-menu a {
    color: rgba(255, 255, 255, 0.7);
}

.primary-menu a:hover,
.footer-menu a:hover {
    color: var(--primary);
}

html.dark .primary-menu a:hover,
html.dark .footer-menu a:hover {
    color: white;
}

.primary-menu .current-menu-item > a {
    color: var(--primary);
    font-weight: 700;
}

html.dark .primary-menu .current-menu-item > a {
    color: white;
}

/* ============================================
   LAYOUT - MAIN
   ============================================ */
.site-main {
    flex-grow: 1;
    min-height: 500px;
    padding: var(--spacing-2xl) 0;
}

.container {
    max-width: 80rem;
    margin: 0 auto;
    padding: 0 var(--spacing-lg);
}

/* ============================================
   LAYOUT - FOOTER
   ============================================ */
.site-footer {
    background-color: var(--background-light);
    border-top: 1px solid var(--border-light);
    padding: var(--spacing-3xl) var(--spacing-lg);
    margin-top: var(--spacing-4xl);
}

html.dark .site-footer {
    background-color: var(--background-dark);
    border-top-color: var(--border-dark);
}

.site-footer .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: var(--spacing-xl);
}

.site-footer p {
    margin: 0;
    font-size: 0.875rem;
    color: var(--text-secondary-light);
}

html.dark .site-footer p {
    color: rgba(255, 255, 255, 0.6);
}

/* ============================================
   CONTENT SECTIONS
   ============================================ */
.entry-header {
    margin-bottom: var(--spacing-2xl);
}

.entry-title {
    font-size: 2.25rem;
    margin-bottom: var(--spacing-lg);
}

.entry-content {
    line-height: 1.8;
    max-width: 48rem;
}

.entry-content p {
    margin-bottom: var(--spacing-lg);
}

.entry-content > :last-child {
    margin-bottom: 0;
}

/* ============================================
   UTILITY CLASSES
   ============================================ */

/* Flexbox utilities */
.flex { display: flex; }
.flex-col { flex-direction: column; }
.flex-row { flex-direction: row; }
.flex-wrap { flex-wrap: wrap; }
.items-center { align-items: center; }
.items-start { align-items: flex-start; }
.items-end { align-items: flex-end; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.justify-end { justify-content: flex-end; }
.gap-2 { gap: var(--spacing-sm); }
.gap-3 { gap: var(--spacing-md); }
.gap-4 { gap: var(--spacing-lg); }
.gap-6 { gap: var(--spacing-2xl); }
.gap-8 { gap: var(--spacing-3xl); }

/* Grid utilities */
.grid { display: grid; }
.grid-cols-1 { grid-template-columns: repeat(1, minmax(0, 1fr)); }
.grid-cols-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }

/* Padding utilities */
.p-2 { padding: var(--spacing-sm); }
.p-4 { padding: var(--spacing-lg); }
.p-6 { padding: var(--spacing-2xl); }
.p-8 { padding: var(--spacing-3xl); }
.px-4 { padding-left: var(--spacing-lg); padding-right: var(--spacing-lg); }
.py-6 { padding-top: var(--spacing-2xl); padding-bottom: var(--spacing-2xl); }
.py-8 { padding-top: var(--spacing-3xl); padding-bottom: var(--spacing-3xl); }
.py-12 { padding-top: 3rem; padding-bottom: 3rem; }

/* Margin utilities */
.m-0 { margin: 0; }
.mt-2 { margin-top: var(--spacing-sm); }
.mt-4 { margin-top: var(--spacing-lg); }
.mt-6 { margin-top: var(--spacing-2xl); }
.mb-2 { margin-bottom: var(--spacing-sm); }
.mb-4 { margin-bottom: var(--spacing-lg); }
.mb-6 { margin-bottom: var(--spacing-2xl); }
.mb-8 { margin-bottom: var(--spacing-3xl); }
.mx-auto { margin-left: auto; margin-right: auto; }

/* Width utilities */
.w-full { width: 100%; }
.w-1/2 { width: 50%; }
.max-w-2xl { max-width: 42rem; }
.max-w-3xl { max-width: 48rem; }
.max-w-4xl { max-width: 56rem; }
.max-w-5xl { max-width: 64rem; }
.max-w-7xl { max-width: 80rem; }

/* Display utilities */
.hidden { display: none; }
.block { display: block; }
.inline { display: inline; }
.inline-flex { display: inline-flex; }

/* Text utilities */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }
.text-sm { font-size: 0.875rem; }
.text-base { font-size: 1rem; }
.text-lg { font-size: 1.125rem; }
.text-xl { font-size: 1.25rem; }
.text-2xl { font-size: 1.5rem; }
.text-3xl { font-size: 1.875rem; }
.text-4xl { font-size: 2.25rem; }
.text-5xl { font-size: 3rem; }
.text-6xl { font-size: 3.75rem; }
.font-medium { font-weight: 500; }
.font-bold { font-weight: 700; }
.font-black { font-weight: 900; }
.italic { font-style: italic; }
.not-italic { font-style: normal; }
.uppercase { text-transform: uppercase; }
.tracking-tight { letter-spacing: -0.015em; }
.tracking-tighter { letter-spacing: -0.033em; }
.leading-tight { line-height: 1.25; }
.leading-snug { line-height: 1.375; }
.leading-relaxed { line-height: 1.625; }

/* Color utilities */
.text-primary { color: var(--primary); }
.text-white { color: white; }
.text-gray-300 { color: #d1d5db; }
.text-gray-400 { color: #9ca3af; }
.text-gray-500 { color: #6b7280; }
.text-gray-600 { color: #4b5563; }
.text-gray-700 { color: #374151; }
.text-gray-800 { color: #1f2937; }
.text-gray-900 { color: #111827; }
.text-white/80 { color: rgba(255, 255, 255, 0.8); }
.text-white/60 { color: rgba(255, 255, 255, 0.6); }
.bg-white { background-color: white; }
.bg-primary { background-color: var(--primary); }
.bg-primary/10 { background-color: rgba(17, 50, 212, 0.1); }
.bg-primary/20 { background-color: rgba(17, 50, 212, 0.2); }
.bg-primary/30 { background-color: rgba(17, 50, 212, 0.3); }
.bg-gray-100 { background-color: #f3f4f6; }
.bg-gray-200 { background-color: #e5e7eb; }
.bg-white/5 { background-color: rgba(255, 255, 255, 0.05); }
.bg-white/10 { background-color: rgba(255, 255, 255, 0.1); }

/* Border utilities */
.border { border: 1px solid var(--border-light); }
.border-t { border-top: 1px solid var(--border-light); }
.border-b { border-bottom: 1px solid var(--border-light); }
.border-primary { border-color: var(--primary); }
.border-2 { border-width: 2px; }
.rounded { border-radius: var(--radius-sm); }
.rounded-lg { border-radius: var(--radius-lg); }
.rounded-xl { border-radius: var(--radius-xl); }
.rounded-full { border-radius: var(--radius-full); }

/* Shadow utilities */
.shadow-sm { box-shadow: 0 1px 2px 0 rgba(0, 0, 0, 0.05); }
.shadow-lg { box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1); }

/* Opacity utilities */
.opacity-50 { opacity: 0.5; }

/* ============================================
   CUSTOM LOGO
   ============================================ */
.custom-logo {
    max-height: 32px;
    max-width: 32px;
    width: auto;
    height: auto;
    display: block;
    border-radius: 8px;
}

.custom-logo-link {
    display: flex;
    align-items: center;
    justify-content: center;
}

/* ============================================
   MATERIAL SYMBOLS ICONS
   ============================================ */
@import url('https://fonts.googleapis.com/css2?family=Material+Symbols+Outlined:opsz,wght,FILL,GRAD@20..48,100..700,0..1,-50..200');

.material-symbols-outlined {
    font-family: 'Material Symbols Outlined';
    font-weight: normal;
    font-style: normal;
    font-size: 24px;
    display: inline-block;
    line-height: 1;
    text-transform: none;
    letter-spacing: normal;
    word-wrap: normal;
    white-space: nowrap;
    direction: ltr;
}

/* ============================================
   RESPONSIVE DESIGN
   ============================================ */
@media (max-width: 768px) {
    h1 { font-size: 1.875rem; }
    h2 { font-size: 1.5rem; }

    .site-header {
        padding: var(--spacing-md) var(--spacing-md);
    }

    .main-navigation {
        display: none;
    }

    .primary-menu {
        flex-direction: column;
        gap: var(--spacing-md);
    }

    .grid-cols-2,
    .grid-cols-3,
    .grid-cols-4 {
        grid-template-columns: repeat(1, minmax(0, 1fr));
    }

    .site-footer .container {
        flex-direction: column;
        text-align: center;
    }

    .site-main {
        padding: var(--spacing-xl) 0;
    }
}

@media (min-width: 769px) and (max-width: 1024px) {
    .grid-cols-4 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* ============================================
   DARK MODE
   ============================================ */
html.dark {
    color-scheme: dark;
}

html.dark .bg-white {
    background-color: var(--background-dark);
}

html.dark .border {
    border-color: var(--border-dark);
}

html.dark .text-gray-600 {
    color: rgba(255, 255, 255, 0.7);
}

html.dark .text-gray-700 {
    color: rgba(255, 255, 255, 0.6);
}