/* =============================================================================
   HND My Account — täielik stilistika
   Kehtib .woocommerce-MyAccount-* elementidele
   ============================================================================= */

/* Layout wrapper */
.woocommerce-account .woocommerce {
    
    grid-template-columns: 240px 1fr;
    gap: 32px;
    align-items: start;
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 24px 64px;
}

.wp-content-block {
    padding-top: 6rem !important;
    padding-bottom: 2rem !important;
}

@media (max-width: 768px) {
    .woocommerce-account .woocommerce {
        grid-template-columns: 1fr;
        gap: 24px;
        padding: 0 16px 48px;
    }

    .woocommerce-MyAccount-navigation {
        position: static !important;
        top: auto !important;
    }

    .wp-content-block {
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
}
}

.woocommerce-account .woocommerce-MyAccount-navigation li {
    list-style: none;
    padding: 0 !important;
}

/* =============================================================================
   SIDEBAR NAVIGATSIOON
   ============================================================================= */

.woocommerce-MyAccount-navigation {
    position: sticky;
    top: 96px;
}

.woocommerce-MyAccount-navigation ul {
    list-style: none;
    margin: 0;
    padding: 0;
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    overflow: hidden;
}

.woocommerce-MyAccount-navigation ul li {
    margin: 0;
    border-bottom: 1px solid #f1f5f9;
}

.woocommerce-MyAccount-navigation ul li:last-child {
    border-bottom: none;
}

.woocommerce-MyAccount-navigation ul li a {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    font-size: 14px;
    font-weight: 500;
    color: #475569;
    text-decoration: none;
    transition: background .15s, color .15s;
    position: relative;
}

.woocommerce-MyAccount-navigation ul li a:hover {
    background: #f8fafc;
    color: #0f172a;
}

.woocommerce-MyAccount-navigation ul li.is-active a {
    background: rgba(153, 0, 224, 0.06);
    color: #9900E0;
    font-weight: 700;
}

.woocommerce-MyAccount-navigation ul li.is-active a::before {
    content: '';
    position: absolute;
    left: 0;
    top: 0;
    bottom: 0;
    width: 3px;
    background: linear-gradient(180deg, #18A5FF, #9900E0);
    border-radius: 0 2px 2px 0;
}

/* Menüü ikoonid — data-atribuudi kaudu */
.woocommerce-MyAccount-navigation ul li a::after {
    content: '';
    width: 16px;
    height: 16px;
    flex-shrink: 0;
    order: -1;
    background-repeat: no-repeat;
    background-size: contain;
    background-position: center;
    opacity: .5;
}
.woocommerce-MyAccount-navigation ul li.is-active a::after { opacity: 1; }

/* Ikoonid slug järgi */
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--licenses a::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%239900E0' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='11' width='18' height='11' rx='2' ry='2'/%3E%3Cpath d='M7 11V7a5 5 0 0 1 10 0v4'/%3E%3C/svg%3E");
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--dashboard a::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='3' y='3' width='7' height='7'/%3E%3Crect x='14' y='3' width='7' height='7'/%3E%3Crect x='14' y='14' width='7' height='7'/%3E%3Crect x='3' y='14' width='7' height='7'/%3E%3C/svg%3E");
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--orders a::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M14 2H6a2 2 0 0 0-2 2v16a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8z'/%3E%3Cpolyline points='14 2 14 8 20 8'/%3E%3Cline x1='16' y1='13' x2='8' y2='13'/%3E%3Cline x1='16' y1='17' x2='8' y2='17'/%3E%3C/svg%3E");
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--subscriptions a::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M23 4 23 10 17 10'/%3E%3Cpath d='M20.49 15a9 9 0 1 1-2.12-9.36L23 10'/%3E%3C/svg%3E");
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--payment-methods a::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Crect x='1' y='4' width='22' height='16' rx='2' ry='2'/%3E%3Cline x1='1' y1='10' x2='23' y2='10'/%3E%3C/svg%3E");
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--edit-account a::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%236b7280' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M20 21v-2a4 4 0 0 0-4-4H8a4 4 0 0 0-4 4v2'/%3E%3Ccircle cx='12' cy='7' r='4'/%3E%3C/svg%3E");
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--customer-logout a::after {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23ef4444' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4'/%3E%3Cpolyline points='16 17 21 12 16 7'/%3E%3Cline x1='21' y1='12' x2='9' y2='12'/%3E%3C/svg%3E");
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--customer-logout a {
    color: #ef4444;
}
.woocommerce-MyAccount-navigation ul li.woocommerce-MyAccount-navigation-link--customer-logout a:hover {
    background: rgba(239, 68, 68, 0.05);
}

/* =============================================================================
   SISU ALA
   ============================================================================= */

.woocommerce-MyAccount-content {
    min-width: 0;
}

/* Pealkiri */
.woocommerce-MyAccount-content h2,
.woocommerce-MyAccount-content h3 {
    font-size: 22px;
    font-weight: 800;
    color: #0f172a;
    margin: 0 0 20px;
    letter-spacing: -.02em;
}

/* Dashboard tekst */
.woocommerce-MyAccount-content p {
    font-size: 14px;
    color: #64748b;
    line-height: 1.6;
}

/* =============================================================================
   ORDERS TABEL
   ============================================================================= */

.woocommerce-orders-table,
.woocommerce-MyAccount-content table {
    width: 100%;
    border-collapse: collapse;
    font-size: 14px;
    background: #fff;
    border: 1.5px solid #e2e8f0;
    border-radius: 12px;
    overflow: hidden;
}

.woocommerce-orders-table thead,
.woocommerce-MyAccount-content thead {
    background: #f8fafc;
}

.woocommerce-orders-table th,
.woocommerce-MyAccount-content th {
    padding: 12px 16px;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .06em;
    color: #94a3b8;
    text-align: left;
    border-bottom: 1px solid #e2e8f0;
}

.woocommerce-orders-table td,
.woocommerce-MyAccount-content td {
    padding: 14px 16px;
    border-bottom: 1px solid #f1f5f9;
    color: #334155;
    vertical-align: middle;
}

.woocommerce-orders-table tr:last-child td,
.woocommerce-MyAccount-content tr:last-child td {
    border-bottom: none;
}

.woocommerce-orders-table tr:hover td,
.woocommerce-MyAccount-content tr:hover td {
    background: #fafbfc;
}

/* Order status badges */
.woocommerce-orders-table .order-status,
mark.order-status {
    display: inline-flex;
    align-items: center;
    gap: 5px;
    padding: 3px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    background: none;
}
mark.order-status.status-processing,
.order-status-processing { background: rgba(59,130,246,.1); color: #3b82f6; }
mark.order-status.status-completed,
.order-status-completed  { background: rgba(16,185,129,.1); color: #10b981; }
mark.order-status.status-on-hold,
.order-status-on-hold    { background: rgba(245,158,11,.1); color: #f59e0b; }
mark.order-status.status-cancelled,
.order-status-cancelled  { background: rgba(239,68,68,.1);  color: #ef4444; }

/* View button */
.woocommerce-orders-table .woocommerce-button,
.woocommerce-MyAccount-content .button,
.woocommerce-MyAccount-content a.button {
    display: inline-flex;
    align-items: center;
    padding: 7px 14px;
    background: #f1f5f9;
    color: #475569 !important;
    border: 1px solid #e2e8f0;
    border-radius: 7px;
    font-size: 13px;
    font-weight: 600;
    text-decoration: none;
    transition: background .15s, color .15s;
    cursor: pointer;
}
.woocommerce-MyAccount-content .button:hover,
.woocommerce-MyAccount-content a.button:hover {
    background: #e2e8f0;
    color: #1e293b !important;
    text-decoration: none;
}

/* Primary button */
.woocommerce-MyAccount-content .button.alt,
.woocommerce-MyAccount-content input[type="submit"] {
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    color: #fff !important;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 14px;
}
.woocommerce-MyAccount-content .button.alt:hover,
.woocommerce-MyAccount-content input[type="submit"]:hover {
    opacity: .88;
    background: linear-gradient(135deg, #8b5cf6, #3b82f6);
    color: #fff !important;
}

/* =============================================================================
   SUBSCRIPTIONS
   ============================================================================= */

.woocommerce-MyAccount-content .shop_table.my_account_subscriptions td:last-child {
    white-space: nowrap;
}

/* Subscription actions */
.woocommerce-MyAccount-content .subscription-actions a {
    display: inline-flex;
    padding: 6px 12px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    color: #475569 !important;
    text-decoration: none;
    margin-right: 4px;
    transition: background .15s;
}
.woocommerce-MyAccount-content .subscription-actions a:hover {
    background: #e2e8f0;
    text-decoration: none;
}
.woocommerce-MyAccount-content .subscription-actions a.cancel {
    color: #ef4444 !important;
    background: rgba(239,68,68,.06);
    border-color: rgba(239,68,68,.2);
}

/* =============================================================================
   PAYMENT METHODS
   ============================================================================= */

.woocommerce-MyAccount-content .woocommerce-PaymentMethods table {
    margin-bottom: 20px;
}

/* =============================================================================
   ACCOUNT DETAILS VORM
   ============================================================================= */

.woocommerce-MyAccount-content .woocommerce-EditAccountForm .form-row {
    margin-bottom: 16px;
}

.woocommerce-MyAccount-content .woocommerce-EditAccountForm label {
    display: block;
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #64748b;
    margin-bottom: 6px;
}

.woocommerce-MyAccount-content .woocommerce-EditAccountForm input[type="text"],
.woocommerce-MyAccount-content .woocommerce-EditAccountForm input[type="email"],
.woocommerce-MyAccount-content .woocommerce-EditAccountForm input[type="password"],
.woocommerce-MyAccount-content .woocommerce-EditAccountForm input[type="tel"] {
    width: 100%;
    padding: 10px 14px;
    border: 1.5px solid #e2e8f0;
    border-radius: 8px;
    font-size: 14px;
    color: #1e293b;
    background: #fff;
    outline: none;
    transition: border-color .15s, box-shadow .15s;
    box-sizing: border-box;
}

.woocommerce-MyAccount-content .woocommerce-EditAccountForm input:focus {
    border-color: #9900E0;
    box-shadow: 0 0 0 3px rgba(153,0,224,.08);
}

.woocommerce-MyAccount-content .woocommerce-EditAccountForm fieldset {
    border: 1.5px solid #e2e8f0;
    border-radius: 10px;
    padding: 20px;
    margin: 24px 0 0;
}

.woocommerce-MyAccount-content .woocommerce-EditAccountForm fieldset legend {
    font-size: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: .05em;
    color: #94a3b8;
    padding: 0 8px;
}

/* =============================================================================
   NOTICES
   ============================================================================= */

.woocommerce-MyAccount-content .woocommerce-message,
.woocommerce-MyAccount-content .woocommerce-info,
.woocommerce-MyAccount-content .woocommerce-error {
    padding: 14px 18px;
    border-radius: 10px;
    font-size: 14px;
    margin-bottom: 20px;
    border-left: 4px solid;
    list-style: none;
}

.woocommerce-MyAccount-content .woocommerce-message {
    background: rgba(16,185,129,.08);
    border-color: #10b981;
    color: #065f46;
}

.woocommerce-MyAccount-content .woocommerce-info {
    background: rgba(59,130,246,.08);
    border-color: #3b82f6;
    color: #1e40af;
}

.woocommerce-MyAccount-content .woocommerce-error {
    background: rgba(239,68,68,.08);
    border-color: #ef4444;
    color: #991b1b;
}

/* =============================================================================
   DASHBOARD WELCOME
   ============================================================================= */

.woocommerce-MyAccount-content .woocommerce-MyAccount-content > p:first-child {
    display: none; /* Peida "Hello username" tekst — on menüüs sees */
}
