.mypage-container {
    max-width: 1200px;
    margin: 2rem auto;
}

.mypg-user-info-section {
    background-color: var(--card);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.mypg-user-avatar {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background-color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 2rem;
    font-weight: bold;
}

.mypg-user-details h2 {
    margin: 0 0 0.5rem 0;
    color: var(--text);
}

.mypg-user-stats {
    display: flex;
    gap: 2rem;
    margin-top: 1rem;
}

.stat-item {
    text-align: center;
}

.stat-value {
    font-size: 1.5rem;
    font-weight: bold;
    color: var(--primary);
    display: block;
}

.stat-label {
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h3 {
    margin: 0;
    color: var(--text);
}

.my-servers-section {
    background-color: var(--card);
    padding: 2rem;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.server-management-card {
    background-color: var(--background);
    border: 1px solid var(--divider);
    border-radius: 8px;
    padding: 1.5rem;
    margin-bottom: 1rem;
    transition: all 0.3s ease;
}

.server-management-card:hover {
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.server-card-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 1rem;
}

.server-title {
    font-size: 1.3rem;
    font-weight: bold;
    margin: 0 0 0.5rem 0;
    color: var(--text);
}

.server-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.3rem;
    margin-top: 0.5rem;
}

.server-tag {
    display: inline-block;
    background-color: var(--primary);
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
}

.server-status-container {
    display: flex;
    flex-direction: row;
    gap: 0.5rem;
    align-items: flex-end;
}

.server-status {
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
}

.vote-status {
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
}

.status-active {
    background-color: #d4edda;
    color: #155724;
}

.status-pending {
    background-color: #fff3cd;
    color: #856404;
}

.status-inactive {
    background-color: #f8d7da;
    color: #721c24;
}

.vote-status-enabled {
    background-color: #d4edda;
    color: #155724;
}

.vote-status-disabled {
    background-color: #f8d7da;
    color: #721c24;
}

.ip-status {
    padding: 0.25rem 0.75rem;
    border-radius: 12px;
    font-size: 0.8rem;
    font-weight: bold;
}

.ip-status-public {
    background-color: #d1ecf1;
    color: #0c5460;
}

.ip-status-private {
    background-color: #f8d7da;
    color: #721c24;
}

.server-info-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-bottom: 1rem;
}

.info-item {
    display: flex;
    justify-content: space-between;
    padding: 0.5rem 0;
    border-bottom: 1px solid var(--divider);
}

.info-item:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 500;
    color: var(--text-secondary);
}

.info-value {
    font-weight: bold;
    color: var(--text);
}

.server-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}

.btn-small {
    padding: 0.5rem 1rem;
    font-size: 0.9rem;
}

.btn-danger {
    background-color: #dc3545;
    color: white;
    border: 1px solid #dc3545;
}

.btn-danger:hover {
    background-color: #c82333;
    border-color: #bd2130;
}

.empty-state {
    text-align: center;
    padding: 3rem;
    color: var(--text-secondary);
}

.empty-state-icon {
    font-size: 4rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

.loading-spinner {
    display: flex;
    justify-content: center;
    align-items: center;
    height: 200px;
    font-size: 1.2rem;
    color: var(--text-secondary);
}

.login-required {
    text-align: center;
    padding: 3rem;
    background-color: var(--card);
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.05);
}

.login-required h2 {
    color: var(--text-secondary);
    margin-bottom: 1rem;
}

.delete-confirmation-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 1000;
}

.modal-content {
    background-color: var(--card);
    padding: 2rem;
    border-radius: 8px;
    max-width: 400px;
    margin: 1rem;
}

.modal-header {
    margin-bottom: 1rem;
}

.modal-header h3 {
    margin: 0;
    color: #dc3545;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
}

.btn-vote-settings {
    background-color: #28a745;
    color: white;
    border: 1px solid #28a745;
}

.btn-vote-settings:hover {
    background-color: #218838;
    border-color: #1e7e34;
}

.tag {
    display: inline-block;
    background-color: var(--primary);
    color: white;
    padding: 0.2rem 0.5rem;
    border-radius: 12px;
    font-size: 0.8rem;
    margin-right: 0.3rem;
    margin-bottom: 0.3rem;
}

/* タブレット対応 */
@media (max-width: 1024px) {
    .mypage-container {
        margin: 1rem auto;
        padding: 0 1rem;
    }
    
    .mypg-user-info-section {
        padding: 1.5rem;
    }
    
    .my-servers-section {
        padding: 1.5rem;
    }
    
    .server-management-card {
        padding: 1.25rem;
    }
    
    .server-info-grid {
        grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
    }
}

/* スマホ対応 */
@media (max-width: 768px) {
    .mypage-container {
        margin: 0.5rem auto;
        padding: 0 0.5rem;
    }
    
    .mypg-user-info-section {
        flex-direction: column;
        text-align: center;
        padding: 1rem;
        gap: 0.75rem;
    }
    
    .mypg-user-avatar {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
    
    .mypg-user-details h2 {
        font-size: 1.2rem;
        margin-bottom: 0.25rem;
    }
    
    .mypg-user-stats {
        justify-content: center;
        gap: 1rem;
        margin-top: 0.5rem;
    }
    
    .stat-value {
        font-size: 1.1rem;
    }
    
    .stat-label {
        font-size: 0.75rem;
    }
    
    .section-header {
        flex-direction: column;
        gap: 0.75rem;
        text-align: center;
        align-items: stretch;
        margin-bottom: 1rem;
    }
    
    .section-header .btn {
        width: 100%;
        text-align: center;
    }
    
    .my-servers-section {
        padding: 1rem;
    }
    
    .server-management-card {
        padding: 0.75rem;
        margin-bottom: 0.75rem;
    }
    
    .server-card-header {
        flex-direction: column;
        gap: 0.5rem;
        align-items: stretch;
        margin-bottom: 0.75rem;
    }
    
    .server-title {
        font-size: 1.1rem;
        margin-bottom: 0.25rem;
    }
    
    .server-status-container {
        flex-direction: row;
        justify-content: center;
        flex-wrap: wrap;
        gap: 0.25rem;
    }
    
    .server-status,
    .vote-status,
    .ip-status {
        padding: 0.15rem 0.5rem;
        font-size: 0.7rem;
    }
    
    .server-info-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 0.5rem;
        margin-bottom: 0.75rem;
    }
    
    .info-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 0.1rem;
        padding: 0.25rem 0;
    }
    
    .info-label {
        font-size: 0.75rem;
        color: var(--text-secondary);
    }
    
    .info-value {
        font-size: 0.85rem;
        font-weight: bold;
    }
    
    .server-actions {
        justify-content: center;
        gap: 0.25rem;
    }
    
    .btn-small {
        padding: 0.4rem 0.6rem;
        font-size: 0.75rem;
        min-width: 60px;
    }
    
    .server-tag {
        font-size: 0.7rem;
        padding: 0.1rem 0.3rem;
    }
    
    .empty-state {
        padding: 1.5rem 0.75rem;
    }
    
    .empty-state-icon {
        font-size: 2.5rem;
        margin-bottom: 0.5rem;
    }
    
    .empty-state h3 {
        font-size: 1.1rem;
        margin-bottom: 0.5rem;
    }
    
    .empty-state p {
        font-size: 0.85rem;
        margin-bottom: 1rem;
    }
    
    .modal-content {
        margin: 0.5rem;
        padding: 1rem;
    }
    
    .modal-actions {
        flex-direction: column;
        gap: 0.5rem;
    }
    
    .modal-actions .btn {
        width: 100%;
    }
}

/* 小さいスマホ対応 */
@media (max-width: 480px) {
    .mypage-container {
        padding: 0 0.25rem;
    }
    
    .mypg-user-info-section {
        padding: 0.75rem;
        gap: 0.5rem;
    }
    
    .mypg-user-avatar {
        width: 50px;
        height: 50px;
        font-size: 1.2rem;
    }
    
    .mypg-user-details h2 {
        font-size: 1.1rem;
    }
    
    .mypg-user-stats {
        gap: 0.75rem;
    }
    
    .stat-value {
        font-size: 1rem;
    }
    
    .stat-label {
        font-size: 0.7rem;
    }
    
    .my-servers-section {
        padding: 0.75rem;
    }
    
    .server-management-card {
        padding: 0.5rem;
        margin-bottom: 0.5rem;
    }
    
    .server-title {
        font-size: 1rem;
    }
    
    .server-info-grid {
        grid-template-columns: 1fr;
        gap: 0.25rem;
    }
    
    .info-item {
        flex-direction: row;
        justify-content: space-between;
        padding: 0.15rem 0;
    }
    
    .info-label {
        font-size: 0.7rem;
    }
    
    .info-value {
        font-size: 0.8rem;
    }
    
    .server-actions {
        gap: 0.2rem;
    }
    
    .btn-small {
        padding: 0.3rem 0.5rem;
        font-size: 0.7rem;
        min-width: 50px;
    }
    
    .server-tag {
        font-size: 0.65rem;
        padding: 0.1rem 0.25rem;
    }
    
    .empty-state {
        padding: 1rem 0.5rem;
    }
    
    .empty-state-icon {
        font-size: 2rem;
    }
    
    .empty-state h3 {
        font-size: 1rem;
    }
    
    .empty-state p {
        font-size: 0.8rem;
    }
}