/******************************************************************************/
/*                                                                            */
/* rexx-dark.css - Sample CSS for Rexx highlighting, dark background          */
/* =================================================================          */
/*                                                                            */
/* This program is part of the Rexx Parser package                            */
/* [See https://rexx.epbcn.com/rexx-parser/]                                  */
/*                                                                            */
/* Copyright (c) 2024-2026 Josep Maria Blasco <josep.maria.blasco@epbcn.com>  */
/*                                                                            */
/* License: Apache License 2.0 (https://www.apache.org/licenses/LICENSE-2.0)  */
/*                                                                            */
/* Version history:                                                           */
/*                                                                            */
/* Date     Version Details                                                   */
/* -------- ------- --------------------------------------------------------- */
/* 20241206    0.1  First public release                                      */
/* 20241209    0.1b New call system                                           */
/* 20241222    0.1c Line number support                                       */
/* 20250103    0.1e Add TUTOR-flavored Unicode classes                        */
/* 20250116    0.1f Add support for sub-keywords                              */
/* 20250328    0.2  Main dir is now rexx-parser instead of rexx[.]parser      */
/* 20250406         Rename fractional numbers to decimal                      */
/* 20250530    0.2c Add support for detailed string highlighting              */
/* 20250624    0.2d Complete refactor to use nesting and "&"                  */
/* 20250630         Add support for doc-comment subelements                   */
/* 20250722         Add styles for rx-dskw                                    */
/* 20251111    0.2e Support customizable line numbers in ANSI                 */
/* 20251213    0.3a (Executor) Add support for named arguments                */
/*                                                                            */
/******************************************************************************/

/******************************************************************************/
/******************************************************************************/
/* BASE SELECTOR: highlight-rexx-dark                                         */
/******************************************************************************/
/******************************************************************************/
/*   Format: "highlight-rexx-<stylename>                                      */
/*   It will apply to the whole CSS file                                      */
/******************************************************************************/

.highlight-rexx-dark {

/******************************************************************************/
/* Default settings                                                           */
/* ================                                                           */
/*                                                                            */
/*   Black background, text at ~80%                                           */
/*   The "rexx" class is used as a fallback when no suitable class is found   */
/*                                                                            */
/******************************************************************************/

  pre, .rexx {
    background-color: black;
    color: #aaa;
  }

/******************************************************************************/
/* Support for line numbers                                                   */
/* ========================                                                   */
/******************************************************************************/

  .rx-lineno  {                         /* ANSI Driver only                   */
    color: #ff0;
    font-style: italic;
  }
  .rx-linebar {                         /* ANSI Driver only                   */
    color: #ff0;
  }

  pre.number-lines {
          padding-left: 50px;
    &.w3 {padding-left: 58px; code:before {width:58px;} }
    &.w4 {padding-left: 65px; code:before {width:65px;} }
    &.w5 {padding-left: 72px; code:before {width:72px;} }
    code:before{
      content: attr(lineno) " | ";
      position:absolute;
      left:10px;
      width:50px;
      text-align:right;
      color: grey;
    }
  }

/******************************************************************************/
/* Whitespace and continuations                                               */
/* ============================                                               */
/******************************************************************************/

  .rx-ws, .rx-cont { color: #cc0; }

/******************************************************************************/
/* Standard (non-doc) comments                                                */
/* ===========================                                                */
/******************************************************************************/

  .rx-cm,                               /* Classic, block comments            */
  .rx-lncm {                            /* Line comments                      */
    color: #0c0;
    font-style: italic;
  }

/******************************************************************************/
/* Doc-comments                                                               */
/* ============                                                               */
/******************************************************************************/

  .rx-doc-comment,                      /* Classic style doc-comments         */
  .rx-doc-comment-markdown {            /* Markdown style doc-comments        */

    color: #93a1ed;                     /* Default values (for "block"..      */
    font-style: italic;                 /* ..highlighting.                    */

    &.rx-doc-comment-armature,          /* Armature, whitespace and main      */
    &.rx-doc-comment-whitespace,        /* description share the same style.  */
    &.rx-doc-comment-main-description {
      color: #93a1ed;
      font-style: italic;
    }
    &.rx-doc-comment-summary {          /* Initial summary statement.         */
      color: yellow;
      text-decoration:underline;
      font-style: normal;
    }
    &.rx-doc-comment-tag {              /* @block-tag                         */
      color: pink;
      font-style: normal;
    }
    &.rx-doc-comment-tag-value {        /* As the name in "@param name".      */
      color: #f6f;
      font-style: normal;
    }
    &.rx-doc-comment-tag-description {  /* Text after @deprecated.            */
      color: teal;
      font-style: italic;
    }
  }

/******************************************************************************/
/* Shebangs                                                                   */
/* ========                                                                   */
/******************************************************************************/

  .rx-shb { color: #f55; font-style: italic; }

/******************************************************************************/
/* Keywords and subkeywords, assignment sequences, and "::"                   */
/* ========================================================                   */
/******************************************************************************/

  .rx-kw,                               /* Keywords                           */
  .rx-skw,                              /* Subkeywords                        */
  .rx-dkw,                              /* Directive keywords                 */
  .rx-dskw,                             /* Directive subkeywords              */
  .rx-asg,                              /* Assignment sequences (incl. "=")   */
  .rx-dir                               /* The directive start "::" sequence  */
  {
    color: #ddd;
    font-weight: bold;
  }

  /* Additionally, directive keywords and subkeywords are underlined          */

  .rx-dkw, .rx-dskw { text-decoration:underline; }

/******************************************************************************/
/* Strings (including taken constants that are strings)                       */
/* ====================================================                       */
/******************************************************************************/

  .rx-str , .rx-bstr, .rx-xstr,         /* Classic Rexx strings               */
  .rx-ystr, .rx-pstr, .rx-gstr, .rx-tstr, .rx-ustr { /* TUTOR Unicode strings */
    color: #64b02a;                     /* the inner part of the string       */
    &.rx-ssuf            {color: #0ff;} /* String suffix                      */
    &.rx-oquo, &.rx-cquo {color: #ff0;} /* Quotes                             */
  }

  /* Taken constants that are strings                                         */

  .rx-const {
    &.rx-ssuf            {color: #0ff;} /* String suffix                      */
    &.rx-oquo, &.rx-cquo {color: #ff0;} /* Quotes                             */
  }

/******************************************************************************/
/* Numbers                                                                    */
/* =======                                                                    */
/******************************************************************************/

  /*--------------------------------------------------------------------------*/
  /* Simple highlighting classes (not used by the highlighter)                */
  /*--------------------------------------------------------------------------*/

  .rx-int,                              /* Integers                           */
  .rx-deci,                             /* Decimals (w/ a dot, no exponent)   */
  .rx-exp {                             /* Exponentials (w/ or w/o a dot)     */
    color:#3cc;
  }

  /*--------------------------------------------------------------------------*/
  /* Detailed highlighting (includes non X and B strings that are numbers)    */
  /*--------------------------------------------------------------------------*/

  .rx-nsign { color: #93a1ed; }         /* Number sign (for strings only)     */


  .rx-ipart,                            /* Integer part                       */
  .rx-fpart,                            /* Fractional part                    */
  .rx-expon                             /* The exponent itself                */
  {
    color:#3cc;
  }

  .rx-dpoint { color: #93a1ed; }        /* The decimal point                  */
  .rx-emark  { color: #93a1ed; }        /* The exponent mark ("E" or "e")     */
  .rx-esign  { color: #93a1ed; }        /* The (optional) exponent sign       */

/******************************************************************************/
/* Variables and constant symbols                                             */
/* ==============================                                             */
/******************************************************************************/

  /* Set a common color for all variables                                     */
  .rx-var, .rx-xvar, .rx-stem, .rx-xstem, .rx-cmp, .rx-xcmp { color: #f6f; }

  /* Additionally, exposed variables will be italicized                       */
  .rx-xvar, .rx-xstem, .rx-xcmp { font-style: italic; }

  /* Environment symbols                                                      */
  .rx-env { color: #fc0; font-style: italic; }

  /* Const symbols that are not environment symbols                           */
  .rx-lit { color: #08f; }

/******************************************************************************/
/* Special characters                                                         */
/* ==================                                                         */
/******************************************************************************/

  .rx-spe { color:#f00; }

/******************************************************************************/
/* Operators                                                                  */
/* =========                                                                  */
/******************************************************************************/

  .rx-op  { color:#4f4; }

/******************************************************************************/
/* Taken constants                                                            */
/* ===============                                                            */
/*                                                                            */
/*   I.e., tokens that are "strings or symbols taken as a constant".          */
/*   In the case of strings, quotes and suffixes are assignes styles under    */
/*   "strings".                                                               */
/******************************************************************************/

  .rx-const {

    /*------------------------------------------------------------------------*/
    /* Default highlighting                                                   */
    /*------------------------------------------------------------------------*/

    color: #48c;

    /*------------------------------------------------------------------------*/
    /* Named arguments (Executor)                                             */
    /*------------------------------------------------------------------------*/

    &.rx-argument-name {
      color:#ff0;                       /* Color                             */
    }

    /*------------------------------------------------------------------------*/
    /* Built-in functions and procedures                                      */
    /*------------------------------------------------------------------------*/

    &.rx-bif-func, &.rx-bif-proc {
      color:#6ad;                       /* Color (symbols and strings)        */
      &.rx-ssuf {color: #0ff;}          /* Suffix (for strings)               */
      &.rx-oquo,                        /* Quotes (for strings)               */
      &.rx-cquo {color: #ff0;}
    }

    /*------------------------------------------------------------------------*/
    /* Internal functions and procedures, labels and block instruction names  */
    /*------------------------------------------------------------------------*/

    &.rx-int-func, &.rx-int-proc, &.rx-block, &.rx-label {
      color:#fa0;                       /* Color (symbols and strings)        */
      &.rx-ssuf {color: #0ff;}          /* Suffix (for strings)               */
      &.rx-oquo,                        /* Quotes (for strings)               */
      &.rx-cquo {color: #ff0;}
    }

    /*------------------------------------------------------------------------*/
    /* ::ROUTINE names, ::ROUTINE function and procedure calls,               */
    /* and namespace-qualified ::ROUTINEs                                     */
    /*------------------------------------------------------------------------*/

    &.rx-routine, &.rx-pkg-func, &.rx-pkg-proc, &.rx-ext-pkg-func,
    &.rx-ext-pkg-proc {
      color:#f0a;                       /* Color (symbols and strings)        */
      &.rx-ssuf {color: #0ff;}          /* Suffix (for strings)               */
      &.rx-oquo,                        /* Quotes (for strings)               */
      &.rx-cquo {color: #ff0;}
    }

    /*------------------------------------------------------------------------*/
    /* External calls                                                         */
    /*------------------------------------------------------------------------*/

    &.rx-ext-func, &.rx-ext-proc {
      color:#f0a;                       /* Color (symbols and strings)        */
      font-style: italic;               /* Italic (symbols and strings)       */
      &.rx-ssuf {color: #0ff;}          /* Suffix (for strings)               */
      &.rx-oquo,                        /* Quotes (for strings)               */
      &.rx-cquo {color: #ff0;}
    }

    /*------------------------------------------------------------------------*/
    /* Method names                                                           */
    /*------------------------------------------------------------------------*/

    &.rx-method {
      color:bisque;                     /* Color (symbols and strings)        */
      font-style: italic;               /* Italic (symbols and strings)       */
      &.rx-ssuf {color: #0ff;}          /* Suffix (for strings)               */
      &.rx-oquo,                        /* Quotes (for strings)               */
      &.rx-cquo {color: #ff0;}
    }

    /*------------------------------------------------------------------------*/
    /* Namespace names                                                        */
    /*------------------------------------------------------------------------*/

    &.rx-namespace {
      color: #cc0;                      /* Color (symbols and strings)        */
      &.rx-ssuf {color: #0ff;}          /* Suffix (for strings)               */
      &.rx-oquo,                        /* Quotes (for strings)               */
      &.rx-cquo {color: #ff0;}
    }

    /*------------------------------------------------------------------------*/
    /* Resources                                                              */
    /*------------------------------------------------------------------------*/

    /* Resource name                                                          */
    &.rx-resource {
    color: #fc0;                        /* Color (symbols and strings)        */
      &.rx-ssuf {color: #0ff;}          /* Suffix (for strings)               */
      &.rx-oquo,                        /* Quotes (for strings)               */
      &.rx-cquo {color: #ff0;}
    }

    /* Resource delimiter                                                     */
    .rx-res-delimiter {
      color: #fc0;
      text-decoration:underline;
    }

  } /* <-- END OF .rx-const                                                   */

/******************************************************************************/
/* ::RESOURCE data and ignored stuff                                          */
/******************************************************************************/

  /* Resource data                                                            */
  .rx-res-data {
    color: #fc0;
    font-style: italic;
  }

  /* Resource ignored stuff                                                   */
  .rx-res-ignore {
    color: #ccc;
    font-style: italic;
  }

/******************************************************************************/
/******************************************************************************/
/* END highlight-rexx-dark                                                    */
/******************************************************************************/
/******************************************************************************/

} /* <--- END OF highlight-rexx-dark                                          */

/******************************************************************************/
/******************************************************************************/
/* END OF BASE SELECTOR highlight-rexx-dark                                   */
/******************************************************************************/
/******************************************************************************/
