/* Legal Pages Specific Styles */

/* Header Link Override - 白色統一 */
.nav-link {
    color: #cccccc !important;
}

.nav-link:hover,
.nav-link.active {
    color: #ffffff !important;
}

.logo,
.logo-text {
    color: #ffffff !important;
    text-decoration: none !important;
}

/* Legal Content Layout */
.legal-content {
    padding: 80px 0 100px;
    background: var(--dark);
}

.legal-wrapper {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 60px;
    align-items: start;
}

/* Table of Contents */
.legal-toc {
    position: sticky;
    top: 100px;
    background: var(--gray-dark);
    padding: 30px;
    border: 1px solid var(--white-faint);
}

.legal-toc h3 {
    font-size: 16px;
    font-weight: 500;
    letter-spacing: 1px;
    margin-bottom: 20px;
    color: var(--white);
}

.legal-toc ul {
    list-style: none;
    padding: 0;
}

.legal-toc li {
    margin-bottom: 12px;
}

.legal-toc a {
    color: var(--white-muted);
    text-decoration: none;
    font-size: 14px;
    transition: var(--transition);
    display: block;
    padding: 5px 0;
    border-left: 2px solid transparent;
    padding-left: 10px;
}

.legal-toc a:hover,
.legal-toc a.active {
    color: var(--white);
    border-left-color: var(--white);
}

/* Legal Main Content */
.legal-main {
    max-width: 900px;
}

.last-updated {
    margin-bottom: 40px;
    padding: 20px;
    background: var(--gray-dark);
    border-left: 3px solid var(--white);
}

.last-updated p {
    font-size: 14px;
    color: var(--white-muted);
    margin-bottom: 5px;
}

.last-updated p:last-child {
    margin-bottom: 0;
}

.legal-intro {
    margin-bottom: 60px;
    font-size: 16px;
    line-height: 1.8;
    color: var(--white-dim);
}

/* Legal Sections */
.legal-section {
    margin-bottom: 60px;
    padding-bottom: 60px;
    border-bottom: 1px solid var(--white-faint);
}

.legal-section:last-of-type {
    border-bottom: none;
}

.legal-section h2 {
    font-size: 28px;
    font-weight: 300;
    margin-bottom: 30px;
    letter-spacing: 1px;
    padding-top: 80px;
    margin-top: -80px;
}

.legal-section h3 {
    font-size: 20px;
    font-weight: 400;
    margin: 30px 0 20px;
    color: var(--white);
}

.legal-section p {
    font-size: 15px;
    line-height: 1.8;
    color: var(--white-muted);
    margin-bottom: 20px;
}

.legal-section ol,
.legal-section ul {
    margin: 20px 0;
    padding-left: 30px;
}

.legal-section li {
    font-size: 15px;
    line-height: 1.8;
    color: var(--white-muted);
    margin-bottom: 10px;
}

.legal-section ol li {
    list-style-type: decimal;
}

.legal-section ul li {
    list-style-type: disc;
}

.legal-section ul ul {
    margin-top: 10px;
    margin-bottom: 10px;
}

/* Contact Info Box */
.contact-info-box {
    margin: 30px 0;
    padding: 30px;
    background: var(--gray-dark);
    border: 1px solid var(--white-faint);
}

.contact-info-box h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: var(--white);
}

.contact-info-box dl {
    display: grid;
    grid-template-columns: 140px 1fr;
    margin-bottom: 15px;
}

.contact-info-box dt {
    font-size: 14px;
    color: var(--white-muted);
    font-weight: 500;
}

.contact-info-box dd {
    font-size: 14px;
    color: var(--white);
}

/* Policy Box */
.policy-box {
    padding: 25px;
    background: rgba(255, 255, 255, 0.03);
    border-left: 3px solid var(--white);
    margin: 20px 0;
}

.policy-box h3 {
    margin-top: 0;
}

/* Important Note */
.important-note {
    padding: 20px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    margin: 30px 0;
}

.important-note p {
    margin: 0;
    color: var(--white);
}

.important-note strong {
    color: #ef4444;
}

/* Tables */
.info-table,
.retention-table {
    width: 100%;
    margin: 30px 0;
    border-collapse: collapse;
}

.info-table th,
.info-table td,
.retention-table th,
.retention-table td {
    padding: 15px;
    text-align: left;
    border: 1px solid var(--white-faint);
}

.info-table th,
.retention-table th {
    background: var(--gray-dark);
    font-weight: 500;
    color: var(--white);
}

.info-table td,
.retention-table td {
    font-size: 14px;
    color: var(--white-muted);
}

/* Purpose List */
.purpose-list {
    counter-reset: purpose-counter;
    list-style: none;
    padding-left: 0;
}

.purpose-list > li {
    position: relative;
    padding-left: 0;
    margin-bottom: 30px;
}

.purpose-list > li::before {
    display: none;
}

/* ネストされたリストのスタイルをリセット */
.purpose-list ul {
    list-style: disc;
    padding-left: 20px;
    margin-top: 10px;
}

.purpose-list ul li {
    padding-left: 0;
    margin-bottom: 5px;
}

.purpose-list ul li::before {
    display: none;
}

/* Rights Grid */
.rights-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin: 30px 0;
}

.right-card {
    padding: 25px;
    background: var(--gray-dark);
    border: 1px solid var(--white-faint);
    transition: var(--transition);
}

.right-card:hover {
    border-color: var(--white);
    transform: translateY(-3px);
}

.right-card h3 {
    font-size: 16px;
    margin: 0 0 10px;
    color: var(--white);
}

.right-card p {
    margin: 0;
    font-size: 14px;
    color: var(--white-muted);
}

/* Security Measures */
.security-measures {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    margin: 30px 0;
}

.measure-item {
    padding: 25px;
    background: var(--gray-dark);
    border-top: 2px solid var(--white);
}

.measure-item h4 {
    font-size: 16px;
    margin-bottom: 15px;
    color: var(--white);
}

.measure-item ul {
    list-style: none;
    padding: 0;
}

.measure-item li {
    padding: 8px 0;
    font-size: 14px;
    color: var(--white-muted);
    position: relative;
    padding-left: 20px;
}

.measure-item li::before {
    content: '✓';
    position: absolute;
    left: 0;
    color: #4ade80;
}

/* Organization Structure */
.org-structure {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
    margin: 20px 0;
}

.org-structure dl {
    padding: 20px;
    background: var(--gray-dark);
    text-align: center;
}

.org-structure dt {
    font-size: 12px;
    color: var(--white-muted);
    margin-bottom: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.org-structure dd {
    font-size: 16px;
    color: var(--white);
    margin: 0;
}

/* Note */
.note {
    font-size: 13px;
    color: var(--white-faint);
    font-style: italic;
    margin-top: 15px;
}

/* Legal Footer */
.legal-footer {
    margin-top: 80px;
    padding-top: 40px;
    border-top: 1px solid var(--white-faint);
    text-align: center;
}

.legal-footer p {
    font-size: 14px;
    color: var(--white-muted);
    margin-bottom: 10px;
}

/* Responsive Design */

/* Tablet and below */
@media (max-width: 1024px) {
    .legal-wrapper {
        grid-template-columns: 1fr;
        gap: 40px;
    }
    
    .legal-toc {
        position: static;
        margin-bottom: 40px;
    }
    
    .security-measures {
        grid-template-columns: 1fr;
    }
    
    .org-structure {
        grid-template-columns: 1fr;
    }
}

/* Mobile */
@media (max-width: 768px) {
    /* Page Hero - ヘッダー重なり修正 */
    .page-hero {
        margin-top: 80px; /* ヘッダーの高さ分のマージン追加 */
        min-height: 40vh;
        padding: 3rem 1rem;
    }
    
    .page-title {
        font-size: 2rem;
    }
    
    .page-subtitle {
        font-size: 1rem;
    }
    
    .legal-section h2 {
        font-size: 24px;
    }
    
    .legal-section h3 {
        font-size: 18px;
    }
    
    .contact-info-box dl {
        grid-template-columns: 1fr;
        gap: 5px;
    }
    
    .contact-info-box dt {
        font-weight: 700;
    }
    
    .rights-grid {
        grid-template-columns: 1fr;
    }
    
    .info-table,
    .retention-table {
        font-size: 12px;
    }
    
    .info-table th,
    .info-table td,
    .retention-table th,
    .retention-table td {
        padding: 10px;
    }
}

@media (max-width: 480px) {
    .legal-toc {
        padding: 20px;
    }
    
    .legal-section {
        margin-bottom: 40px;
        padding-bottom: 40px;
    }
    
    .purpose-list > li {
        padding-left: 35px;
    }
    
    .purpose-list > li::before {
        width: 25px;
        height: 25px;
        font-size: 14px;
    }
}