:root {
    --main-purple: #5D3954;
    --main-purple-dark: #4A2C4A;
    --main-purple-light: #7D5974;
    --bg-cream: #FAF8F5;
    --bg-white: #FFFFFF;
    --text-dark: #333333;
    --text-gray: #666666;
    --gray-disabled: #AAAAAA;
    --border-light: #E5E0DC;
    --accent-gold: #D4AF37;
}

/* Global Reset & Base Styles */
*,
*::before,
*::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'メイリオ', Meiryo, sans-serif;
    background-color: var(--bg-cream);
    color: var(--text-dark);
    line-height: 1.6;
    min-height: 100vh;
}

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

/* Common Header */
.common-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 15px 20px;
    margin-bottom: 30px;
    background: var(--bg-white);
    border-bottom: 1px solid var(--border-light);
    min-height: 80px;
}

.header-left,
.header-right {
    flex: 0 0 100px;
    /* Fixed width to balance the title */
    display: flex;
    align-items: center;
}

.header-right {
    justify-content: flex-end;
}

.header-center {
    flex: 1;
    text-align: center;
}

.common-header .back-link {
    color: var(--main-purple);
    text-decoration: none;
    font-size: 0.85rem;
    font-weight: bold;
    padding: 8px 16px;
    border: 1px solid var(--main-purple);
    border-radius: 20px;
    transition: all 0.2s;
    background: white;
    white-space: nowrap;
    display: inline-block;
}

.common-header .back-link:hover {
    background: var(--main-purple);
    color: white;
}

.common-header .title {
    margin: 0;
}

.common-header .title-sub {
    display: block;
    font-size: 0.8rem;
    color: var(--text-gray);
    letter-spacing: 0.1em;
    margin-bottom: 2px;
}

.common-header .title-main {
    font-size: 1.4rem;
    color: var(--main-purple);
    font-weight: bold;
    letter-spacing: 0.05em;
    line-height: 1.2;
}

/* Common Footer */
.common-footer {
    margin-top: 60px;
    padding: 40px 0;
    text-align: center;
    border-top: 1px solid var(--border-light);
}

.common-footer .footer-text {
    font-size: 0.75rem;
    color: var(--text-gray);
    margin-bottom: 8px;
}

.common-footer .copyright {
    font-size: 0.7rem;
    color: var(--gray-disabled);
}

.common-footer .copyright a {
    color: var(--main-purple);
    text-decoration: none;
    transition: text-decoration 0.2s;
}

.common-footer .copyright a:hover {
    text-decoration: underline;
}

/* Responsive */
@media (max-width: 600px) {
    .common-header {
        padding: 10px;
        min-height: 70px;
    }

    .header-left,
    .header-right {
        flex: 0 0 70px;
    }

    .common-header .back-link {
        padding: 6px 10px;
        font-size: 0.7rem;
        border-radius: 15px;
    }

    .common-header .title-main {
        font-size: 1.1rem;
    }

    .common-header .title-sub {
        font-size: 0.65rem;
    }
}

/* Navigation Footer */
.nav-footer {
    margin-top: 40px;
    text-align: center;
}

.nav-footer a {
    color: var(--main-purple);
    text-decoration: none;
    font-size: 0.95rem;
    font-weight: bold;
}

.nav-footer a:hover {
    text-decoration: underline;
}